diff options
author | Alex Auvolat <alex@adnab.me> | 2022-12-01 17:05:32 +0100 |
---|---|---|
committer | Alex Auvolat <alex@adnab.me> | 2022-12-01 17:05:32 +0100 |
commit | ee18ddcebcdd5744f7a5abaecfd1c4441ba69c35 (patch) | |
tree | 4e7cdfd3802eb6d50d73d61d61f549f24c7ceb8b /flake.nix | |
parent | 0ae7f5fbd924a293dcd3f1b6b61fc3cc46bd3876 (diff) | |
download | tricot-ee18ddcebcdd5744f7a5abaecfd1c4441ba69c35.tar.gz tricot-ee18ddcebcdd5744f7a5abaecfd1c4441ba69c35.zip |
Add Drone CI
Diffstat (limited to 'flake.nix')
-rw-r--r-- | flake.nix | 25 |
1 files changed, 15 insertions, 10 deletions
@@ -15,17 +15,22 @@ overlays = [ cargo2nix.overlays.default ]; }; packageFun = import ./Cargo.nix; - packageSet = pkgs.rustBuilder.makePackageSet { - inherit packageFun; - release = true; - rustVersion = "1.63.0"; - }; - tricot = packageSet.workspace.tricot { - compileMode = "build"; - }; + rustVersion = "1.63.0"; + + compile = args: compileMode: + let + packageSet = pkgs.rustBuilder.makePackageSet ({ + inherit packageFun rustVersion; + } // args); + in + packageSet.workspace.tricot { + inherit compileMode; + }; in { - packages.x86_64-linux.tricot = tricot; - packages.x86_64-linux.default = tricot; + test.x86_64-linux.tricot = compile { release = false; } "test"; + debug.x86_64-linux.tricot = compile { release = false; } "build"; + packages.x86_64-linux.tricot = compile { release = true; } "build"; + packages.x86_64-linux.default = self.packages.x86_64-linux.tricot; }; } |