Fix rust flake template
This commit is contained in:
parent
74032212ae
commit
a96bf2ad36
1 changed files with 7 additions and 12 deletions
|
@ -4,19 +4,14 @@
|
||||||
self,
|
self,
|
||||||
nixpkgs,
|
nixpkgs,
|
||||||
}: let
|
}: let
|
||||||
|
inherit (self) outputs;
|
||||||
supportedSystems = ["x86_64-linux"];
|
supportedSystems = ["x86_64-linux"];
|
||||||
forEachSupportedSystem = f:
|
forEachSupportedSystem = nixpkgs.lib.genAttrs supportedSystems;
|
||||||
nixpkgs.lib.genAttrs supportedSystems (system:
|
|
||||||
f {
|
|
||||||
inherit system;
|
|
||||||
pkgs = import nixpkgs {inherit system;};
|
|
||||||
});
|
|
||||||
in {
|
in {
|
||||||
devShells = forEachSupportedSystem ({
|
devShells = forEachSupportedSystem (system: let
|
||||||
pkgs,
|
pkgs = import nixpkgs {inherit system;};
|
||||||
system,
|
in {
|
||||||
}: {
|
rust-dev = pkgs.mkShell {
|
||||||
rust-development = pkgs.mkShell {
|
|
||||||
buildInputs = with pkgs; [
|
buildInputs = with pkgs; [
|
||||||
cargo
|
cargo
|
||||||
rustc
|
rustc
|
||||||
|
@ -26,7 +21,7 @@
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
default = forEachSupportedSystem ({system, ...}: self.outputs.${system}.rust-development);
|
default = outputs.devShells.${system}.rust-dev;
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue