-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathflake.nix
More file actions
executable file
·179 lines (150 loc) · 4.88 KB
/
Copy pathflake.nix
File metadata and controls
executable file
·179 lines (150 loc) · 4.88 KB
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
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
{
description = "NixOS hyprland setup";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
hardware.url = "github:nixos/nixos-hardware";
nix-colors.url = "github:misterio77/nix-colors";
home-manager = {
url = "github:nix-community/home-manager";
inputs.nixpkgs.follows = "nixpkgs";
};
sops-nix = {
url = "github:Mic92/sops-nix";
inputs.nixpkgs.follows = "nixpkgs";
};
hyprland = {
url = "github:hyprwm/hyprland";
inputs.nixpkgs.follows = "nixpkgs";
};
hyprland-plugins = {
url = "github:hyprwm/hyprland-plugins";
inputs.hyprland.follows = "hyprland";
};
catppuccin.url = "github:catppuccin/nix";
# Prebuilt nixpkgs file->package index, kept up to date automatically
# via `nix flake update`. Backs `comma`/command-not-found so unknown
# commands can be searched and run sandboxed without ever having to
# build a local index.
nix-index-database = {
url = "github:nix-community/nix-index-database";
inputs.nixpkgs.follows = "nixpkgs";
};
ghostty = {
url = "github:ghostty-org/ghostty";
};
winapps = {
url = "github:winapps-org/winapps";
inputs.nixpkgs.follows = "nixpkgs";
};
labrador = {
url = "github:espotek-org/Labrador?rev=3119205cdde183039062621c1204584f1ec1c5ac";
inputs.nixpkgs.follows = "nixpkgs";
};
};
outputs = {
self,
nixpkgs,
home-manager,
catppuccin,
ghostty,
labrador,
...
} @ inputs:
let
inherit (self) outputs;
lib = nixpkgs.lib // home-manager.lib;
systems = ["x86_64-linux"];
forEachSystem = f: lib.genAttrs systems (system: f pkgsFor.${system});
pkgsFor = lib.genAttrs systems (system:
import nixpkgs {
inherit system;
config.allowUnfree = true;
}
);
#labrador-fixed = lib.genAttrs systems (system:
# labrador.packages.${system}.default.overrideAttrs (old: {
# src = pkgsFor.${system}.fetchFromGitHub {
# owner = "espotek-org";
# repo = "Labrador";
# rev = "3119205cdde183039062621c1204584f1ec1c5ac";
# hash = "sha256-ERSHtiuq1l3sEk5OdVxoG1ri/4HZ0Fi4KFkWW09ZKyI=";
# fetchSubmodules = true;
# };
# #postPatch = ''
# # echo 'QMAKE_CFLAGS += -std=c11' >> Desktop_Interface/Labrador.pro
# #'';
# })
#);
in {
inherit lib;
myPkgs = forEachSystem (pkgs: import ./pkgs {inherit pkgs;});
formatter = forEachSystem (pkgs: pkgs.alejandra);
devShells = forEachSystem (pkgs: import ./shell.nix { inherit pkgs; });
nixosConfigurations = {
# Desktop
mrgeotech-pc = lib.nixosSystem {
specialArgs = {inherit inputs outputs;};
modules = [
./hosts/mrgeotech-pc
catppuccin.nixosModules.catppuccin
home-manager.nixosModules.home-manager
({config, ...}: {
home-manager.backupFileExtension = "bak";
home-manager.extraSpecialArgs = {
inherit inputs outputs;
inherit (config.networking) hostName;
};
})
];
};
# Laptop
mrgeotech-laptop = lib.nixosSystem {
specialArgs = {inherit inputs outputs;};
modules = [
./hosts/mrgeotech-laptop
home-manager.nixosModules.home-manager
catppuccin.nixosModules.catppuccin
({config, ...}: {
home-manager.backupFileExtension = "bak";
home-manager.extraSpecialArgs = {
inherit inputs outputs;
inherit (config.networking) hostName;
};
})
];
};
# New Laptop (Zenbook)
mrgeotech-zenbook = lib.nixosSystem {
specialArgs = {inherit inputs outputs;};
modules = [
./hosts/mrgeotech-zenbook
home-manager.nixosModules.home-manager
catppuccin.nixosModules.catppuccin
({config, ...}: {
home-manager.backupFileExtension = "bak";
home-manager.extraSpecialArgs = {
inherit inputs outputs;
inherit (config.networking) hostName;
};
})
];
};
# steam-machine
steam-machine = lib.nixosSystem {
specialArgs = {inherit inputs outputs;};
modules = [
./hosts/steam-machine
home-manager.nixosModules.home-manager
catppuccin.nixosModules.catppuccin
({config, ...}: {
home-manager.backupFileExtension = "bak";
home-manager.extraSpecialArgs = {
inherit inputs outputs;
inherit (config.networking) hostName;
};
})
];
};
};
};
}