From 32305cd2db3e3faadf623726e10866f9ce9db1ad Mon Sep 17 00:00:00 2001 From: Alex Auvolat Date: Sun, 2 Feb 2025 20:52:57 +0100 Subject: [PATCH] build release builds with crane in ci --- .woodpecker/release.yaml | 2 +- default.nix | 8 ++------ 2 files changed, 3 insertions(+), 7 deletions(-) diff --git a/.woodpecker/release.yaml b/.woodpecker/release.yaml index a2328d5e..dfa791a3 100644 --- a/.woodpecker/release.yaml +++ b/.woodpecker/release.yaml @@ -18,7 +18,7 @@ steps: - name: build image: nixpkgs/nix:nixos-22.05 commands: - - nix-build --no-build-output --attr pkgs.${ARCH}.release --argstr git_version ${CI_COMMIT_TAG:-$CI_COMMIT_SHA} + - nix-build --attr releasePackages.${ARCH} --argstr git_version ${CI_COMMIT_TAG:-$CI_COMMIT_SHA} - name: check is static binary image: nixpkgs/nix:nixos-22.05 diff --git a/default.nix b/default.nix index 9d8508d9..59955028 100644 --- a/default.nix +++ b/default.nix @@ -6,14 +6,10 @@ let pkgs = import nixpkgs { }; compile = import ./nix/compile.nix; - compileWith = args: compile ({ - inherit system git_version nixpkgs; + build_release = target: (compile { + inherit target system git_version nixpkgs; crane = flake.inputs.crane; rust-overlay = flake.inputs.rust-overlay; - } // args); - - build_release = target: (compile { - inherit target; release = true; }).garage;