define base packages in another module
This commit is contained in:
14
flake.nix
14
flake.nix
@@ -6,10 +6,11 @@
|
||||
nixos-wsl.url = "github:nix-community/NixOS-WSL/main";
|
||||
};
|
||||
outputs = { self, nixpkgs, nixos-wsl, nix, ...}@inputs:
|
||||
let
|
||||
system = if builtins ? currentSystem
|
||||
let system = if builtins ? currentSystem
|
||||
then builtins.currentSystem
|
||||
else "x86_64-linux";
|
||||
pkgs = import nixpkgs { inherit system; };
|
||||
basePackages = (import ./base-packages { inherit pkgs; });
|
||||
in
|
||||
{
|
||||
nixosConfigurations = {
|
||||
@@ -22,6 +23,15 @@
|
||||
system.stateVersion = "24.05";
|
||||
wsl.enable = true;
|
||||
nix.settings.experimental-features = ["nix-command" "flakes" ];
|
||||
environment.systemPackages = basePackages.mkBasePackages.packages [
|
||||
pkgs.wget
|
||||
pkgs.git
|
||||
pkgs.curl
|
||||
];
|
||||
programs.nix-ld = {
|
||||
enable = true;
|
||||
package = pkgs.nix-ld-rs;
|
||||
};
|
||||
}
|
||||
];
|
||||
specialArgs = { inherit inputs; };
|
||||
|
||||
Reference in New Issue
Block a user