-
Notifications
You must be signed in to change notification settings - Fork 7
/
nixos.nix
73 lines (69 loc) · 2.14 KB
/
nixos.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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
# This function creates a NixOS system based on our VM setup for a
# particular architecture.
name: {inputs, nixpkgs, home-manager, system, user }:
nixpkgs.lib.nixosSystem rec {
inherit system;
# NixOS level modules
modules = [
./hardware/${name}.nix
./machines/${name}.nix
./modules/environment.nix
./modules/fonts.nix
./modules/misc.nix
./modules/networking.nix
./modules/nix.nix
./modules/nixpkgs.nix
./modules/openssh.nix
./modules/users.nix
./modules/xrandr.nix
./modules/xserver.nix
./modules/zsh.nix
# The home-manager NixOS module
home-manager.nixosModules.home-manager {
home-manager = {
useGlobalPkgs = true;
useUserPackages = true;
users.cor = {
# Home-manager level modules
imports = [
./home-modules/awesome.nix
./home-modules/bat.nix
./home-modules/chromium.nix
./home-modules/direnv.nix
./home-modules/flameshot.nix
./home-modules/git.nix
./home-modules/gpg.nix
./home-modules/gtk.nix
./home-modules/helix.nix
./home-modules/kitty.nix
./home-modules/lazygit.nix
./home-modules/nixos-misc.nix
./home-modules/nushell.nix
./home-modules/packages.nix
./home-modules/ranger.nix
./home-modules/rofi.nix
./home-modules/tmux.nix
./home-modules/zsh.nix
];
};
# Arguments that are exposed to every `home-module`.
extraSpecialArgs = {
pkgs-unstable = import inputs.nixpkgs-unstable { inherit system; config.allowUnfree = true; };
currentSystemName = name;
currentSystem = system;
theme = "dark"; # "dark" or "light"
isDarwin = false;
inherit inputs;
};
};
}
# Arguments that are exposed to every `module`.
{
config._module.args = {
currentSystemName = name;
currentSystem = system;
pkgs-unstable = import inputs.nixpkgs-unstable { inherit system; config.allowUnfree = true; };
};
}
];
}