简化stable/unstable切换的方式;增加兼容性代码,根据版本引用
This commit is contained in:
15
flake.nix
15
flake.nix
@@ -7,6 +7,19 @@
|
||||
useremail = "reizero@live.com";
|
||||
sourcepath = "/home/${username}/.nix";
|
||||
libs = import ./libs;
|
||||
|
||||
nixos = {
|
||||
stable = {
|
||||
nixpkgs = nixpkgs;
|
||||
home-manager = home-manager;
|
||||
version = "24.11";
|
||||
};
|
||||
unstable = {
|
||||
nixpkgs = nixpkgs-unstable;
|
||||
home-manager = home-manager-unstable;
|
||||
version = "25.05";
|
||||
};
|
||||
};
|
||||
in
|
||||
rec {
|
||||
# Your custom packages and modifications, exported as overlays
|
||||
@@ -20,7 +33,7 @@
|
||||
(profile: {
|
||||
name = profile;
|
||||
value = import ./profiles/${profile} {
|
||||
inherit self inputs outputs libs sourcepath username useremail;
|
||||
inherit self inputs outputs libs nixos sourcepath username useremail;
|
||||
};
|
||||
})
|
||||
(attrNames (readDir ./profiles))
|
||||
|
||||
Reference in New Issue
Block a user