-
Notifications
You must be signed in to change notification settings - Fork 0
/
flake.nix
56 lines (56 loc) · 2.06 KB
/
flake.nix
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
{
inputs = {
nixpkgs.url = "github:nixos/nixpkgs/nixos-23.11";
nixpkgs-unstable.url = "github:nixos/nixpkgs/nixos-unstable";
nixos-hardware.url = "github:nixos/nixos-hardware/master";
home-manager.url = "github:nix-community/home-manager/release-23.11";
home-manager.inputs.nixpkgs.follows = "nixpkgs";
emacs-overlay.url = "github:nix-community/emacs-overlay";
emacs-overlay.inputs.nixpkgs.follows = "nixpkgs-unstable";
};
outputs = { nixpkgs, nixpkgs-unstable, home-manager, emacs-overlay
, nixos-hardware, ... }:
let
system = "x86_64-linux";
overlays = [ emacs-overlay.overlay ];
overlays-config = { nixpkgs.overlays = overlays; };
pkgs = import nixpkgs { inherit system; };
pkgs-unstable = import nixpkgs-unstable { inherit system overlays; };
username = "daniel";
in {
homeConfigurations.c1 = home-manager.lib.homeManagerConfiguration {
inherit pkgs;
modules = [ ./home.nix ./home-c1.nix ./home-gnome.nix ];
extraSpecialArgs.configName = "c1";
extraSpecialArgs = { inherit pkgs-unstable; };
};
homeConfigurations.c2 = home-manager.lib.homeManagerConfiguration {
inherit pkgs;
modules = [ ./home.nix ./home-c2.nix ./home-gnome.nix ];
extraSpecialArgs.configName = "c2";
};
nixosConfigurations.c1 = nixpkgs.lib.nixosSystem {
inherit system;
specialArgs.configName = "c1";
specialArgs.homeUsername = username;
modules = [
# home-manager.nixosModules.home-manager
overlays-config
./configuration.nix
./configuration-c1.nix
];
};
nixosConfigurations.c2 = nixpkgs.lib.nixosSystem {
inherit system;
specialArgs.configName = "c2";
specialArgs.homeUsername = username;
modules = [
# home-manager.nixosModules.home-manager
overlays-config
# nixos-hardware.nixosModules.lenovo-thinkpad-p16s-amd-gen1
./configuration.nix
./configuration-c2.nix
];
};
};
}