me like nix
1{
2 description = "My NixOS Flake Configuration";
3
4 inputs = {
5 # Nixpkgs (stable or unstable)
6 nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
7
8 # Home Manager
9 home-manager = {
10 url = "github:nix-community/home-manager/master";
11 inputs.nixpkgs.follows = "nixpkgs"; # Ensures Home Manager uses the same nixpkgs
12 };
13 catppuccin.url = "github:catppuccin/nix";
14 niri.url = "github:sodiboo/niri-flake";
15 nixarr.url = "github:rasmus-kirk/nixarr";
16 zen-browser = {
17 url = "github:0xc000022070/zen-browser-flake";
18 inputs.nixpkgs.follows = "nixpkgs";
19 };
20 copyparty.url = "github:9001/copyparty";
21 nixos-hardware.url = "github:NixOS/nixos-hardware/master";
22 agenix = {
23 url = "github:ryantm/agenix";
24 inputs.nixpkgs.follows = "nixpkgs";
25 };
26 kaleidux = {
27 url = "github:Mjoyufull/Kaleidux/feat/zerocopy";
28 inputs.nixpkgs.follows = "nixpkgs";
29 };
30 fsel = {
31 url = "github:Mjoyufull/fsel";
32 inputs.nixpkgs.follows = "nixpkgs";
33 };
34 # organelle-hello = {
35 # url = "path:/home/sean/dev/organelle-hello";
36 # inputs.nixpkgs.follows = "nixpkgs";
37 # };
38 trmnl-rs = {
39 url = "github:seanaye/trmnl-rs";
40 inputs.nixpkgs.follows = "nixpkgs";
41 };
42 berkeley-mono = {
43 url = "path:./berkeley-mono-stub";
44 inputs.nixpkgs.follows = "nixpkgs";
45 };
46 mako-tui = {
47 url = "git+https://codeberg.org/seanaye/mako-tui";
48 inputs.nixpkgs.follows = "nixpkgs";
49 };
50 opencodex = {
51 url = "git+https://codeberg.org/seanaye/opencodex";
52 inputs.nixpkgs.follows = "nixpkgs";
53 };
54 nixos-raspberrypi.url = "github:nvmd/nixos-raspberrypi/main";
55 };
56
57 outputs =
58 {
59 self,
60 nixpkgs,
61 home-manager,
62 catppuccin,
63 niri,
64 nixarr,
65 copyparty,
66 nixos-hardware,
67 agenix,
68 nixos-raspberrypi,
69 ...
70 }@inputs:
71 {
72 nixosConfigurations = {
73 # Replace "nixos" with your actual desired hostname if it's different
74 # This "nixos" must match the `networking.hostName` in your configuration.nix
75 mira = nixpkgs.lib.nixosSystem {
76 system = "x86_64-linux";
77 modules = [
78 # Your main configuration file
79 ./hosts/mira/configuration.nix
80 catppuccin.nixosModules.catppuccin
81 agenix.nixosModules.default
82
83 copyparty.nixosModules.default
84
85 ({
86 nixpkgs.overlays = [
87 niri.overlays.niri
88 copyparty.overlays.default
89 ];
90 })
91
92 # nixarr module
93 nixarr.nixosModules.default
94
95 # Home Manager module
96 home-manager.nixosModules.home-manager
97 {
98 home-manager.extraSpecialArgs = { inherit inputs; };
99 home-manager.users.sean = import ./hosts/mira/home.nix;
100 }
101 ];
102 specialArgs = { inherit inputs; };
103 };
104 framework16 = nixpkgs.lib.nixosSystem {
105 system = "x86_64-linux";
106 modules = [
107 # Your main configuration file
108 ./hosts/framework16/configuration.nix
109 catppuccin.nixosModules.catppuccin
110 nixos-hardware.nixosModules.framework-16-7040-amd
111
112 ({
113 nixpkgs.overlays = [ niri.overlays.niri ];
114 })
115
116 # Home Manager module
117 home-manager.nixosModules.home-manager
118 {
119 home-manager.extraSpecialArgs = { inherit inputs; };
120 home-manager.users.sean = import ./hosts/framework16/home.nix;
121 }
122 ];
123 specialArgs = { inherit inputs; };
124 };
125
126 pi = nixpkgs.lib.nixosSystem {
127 system = "aarch64-linux";
128 modules = [
129 "${nixpkgs}/nixos/modules/installer/sd-card/sd-image-aarch64.nix"
130 nixos-hardware.nixosModules.raspberry-pi-4
131 agenix.nixosModules.default
132 ./hosts/pi/configuration.nix
133
134 # Allow missing kernel modules (Pi kernel doesn't have all x86 modules)
135 # See: https://github.com/NixOS/nixpkgs/issues/154163
136 ({
137 nixpkgs.overlays = [
138 (final: super: {
139 makeModulesClosure = x: super.makeModulesClosure (x // { allowMissing = true; });
140 })
141 ];
142 })
143 ];
144 specialArgs = { inherit inputs; };
145 };
146
147 pizero = nixpkgs.lib.nixosSystem {
148 system = "aarch64-linux";
149 modules = [
150 "${nixpkgs}/nixos/modules/installer/sd-card/sd-image-aarch64.nix"
151 agenix.nixosModules.default
152 ./hosts/pizero/configuration.nix
153
154 # Allow missing kernel modules (Pi kernel doesn't have all x86 modules)
155 ({
156 nixpkgs.overlays = [
157 (final: super: {
158 makeModulesClosure = x: super.makeModulesClosure (x // { allowMissing = true; });
159 })
160 ];
161 })
162 ];
163 specialArgs = { inherit inputs; };
164 };
165
166 # organelle = nixpkgs.lib.nixosSystem {
167 # system = "aarch64-linux";
168 # modules = [
169 # "${nixpkgs}/nixos/modules/installer/sd-card/sd-image-aarch64.nix"
170 # agenix.nixosModules.default
171 # ./hosts/organelle/configuration.nix
172 #
173 # ({
174 # nixpkgs.overlays = [
175 # (final: super: {
176 # makeModulesClosure = x: super.makeModulesClosure (x // { allowMissing = true; });
177 # })
178 # ];
179 # })
180 # ];
181 # specialArgs = { inherit inputs; };
182 # };
183
184 kodi-pi = nixos-raspberrypi.lib.nixosSystemFull {
185 specialArgs = { inherit nixos-raspberrypi inputs; };
186 modules = [
187 (
188 { nixos-raspberrypi, ... }:
189 {
190 imports = with nixos-raspberrypi.nixosModules; [
191 raspberry-pi-5.base
192 raspberry-pi-5.page-size-16k
193 raspberry-pi-5.display-vc4
194 ];
195 }
196 )
197 # Disable SDL3 test suite (testprocess fails in Nix sandbox)
198 (
199 { pkgs, ... }:
200 {
201 nixpkgs.overlays = [
202 (final: prev: {
203 sdl3 = prev.sdl3.overrideAttrs (old: {
204 doCheck = false;
205 });
206 })
207 ];
208 }
209 )
210 agenix.nixosModules.default
211 ./hosts/kodi-pi/configuration.nix
212 ];
213 };
214 };
215 };
216}