Kieran's opinionated (and probably slightly dumb) nix config
1{
2 description = "Kieran's opinionated (and probably slightly dumb) nix config";
3
4 inputs = {
5 # Nixpkgs
6 nixpkgs.url = "github:nixos/nixpkgs/nixos-25.05";
7 nixpkgs-unstable.url = "github:nixos/nixpkgs/nixos-unstable";
8
9 # NixOS hardware configuration
10 hardware.url = "github:NixOS/nixos-hardware/master";
11
12 # Home manager
13 home-manager.url = "github:nix-community/home-manager/release-25.05";
14 home-manager.inputs.nixpkgs.follows = "nixpkgs";
15
16 # Nix-Darwin
17 nix-darwin.url = "github:nix-darwin/nix-darwin/nix-darwin-25.05";
18 nix-darwin.inputs.nixpkgs.follows = "nixpkgs";
19
20 disko.url = "github:nix-community/disko";
21 disko.inputs.nixpkgs.follows = "nixpkgs";
22
23 # agenix
24 agenix.url = "github:ryantm/agenix";
25
26 spicetify-nix = {
27 url = "github:Gerg-L/spicetify-nix";
28 inputs.nixpkgs.follows = "nixpkgs";
29 };
30
31 catppuccin = {
32 url = "github:catppuccin/nix?rev=f518f96a60aceda4cd487437b25eaa48d0f1b97d";
33 inputs.nixpkgs.follows = "nixpkgs";
34 };
35
36 catppuccin-vsc = {
37 url = "github:catppuccin/vscode";
38 };
39
40 nix-vscode-extensions.url = "github:nix-community/nix-vscode-extensions";
41
42 frc-nix = {
43 url = "github:frc4451/frc-nix";
44 inputs.nixpkgs.follows = "nixpkgs";
45 };
46
47 claude-desktop = {
48 url = "github:k3d3/claude-desktop-linux-flake";
49 inputs.nixpkgs.follows = "nixpkgs";
50 };
51
52 hyprland-contrib = {
53 url = "github:hyprwm/contrib";
54 inputs.nixpkgs.follows = "nixpkgs";
55 };
56
57 nixvim.url = "github:taciturnaxolotl/nixvim";
58
59 terminal-wakatime = {
60 url = "github:taciturnaxolotl/terminal-wakatime";
61 inputs.nixpkgs.follows = "nixpkgs";
62 };
63
64 ctfd-alerts = {
65 url = "github:taciturnaxolotl/ctfd-alerts";
66 inputs.nixpkgs.follows = "nixpkgs";
67 };
68
69 flare = {
70 url = "github:ByteAtATime/flare/feat/nix";
71 inputs.nixpkgs.follows = "nixpkgs";
72 };
73
74 import-tree.url = "github:vic/import-tree";
75
76 nur = {
77 url = "github:nix-community/NUR";
78 inputs.nixpkgs.follows = "nixpkgs";
79 };
80
81 cedarlogic = {
82 url = "github:taciturnaxolotl/CedarLogic";
83 inputs.nixpkgs.follows = "nixpkgs";
84 };
85
86 soapdump = {
87 url = "github:taciturnaxolotl/soapdump";
88 inputs.nixpkgs.follows = "nixpkgs";
89 };
90 };
91
92 outputs =
93 {
94 self,
95 nixpkgs,
96 nixpkgs-unstable,
97 agenix,
98 home-manager,
99 nur,
100 nix-darwin,
101 ...
102 }@inputs:
103 let
104 outputs = inputs.self.outputs;
105 unstable-overlays = {
106 nixpkgs.overlays = [
107 (final: prev: {
108 unstable = import nixpkgs-unstable {
109 system = final.system;
110 config.allowUnfree = true;
111 };
112
113 bambu-studio = prev.bambu-studio.overrideAttrs (oldAttrs: {
114 version = "01.00.01.50";
115 src = prev.fetchFromGitHub {
116 owner = "bambulab";
117 repo = "BambuStudio";
118 rev = "v01.00.01.50";
119 hash = "sha256-7mkrPl2CQSfc1lRjl1ilwxdYcK5iRU//QGKmdCicK30=";
120 };
121 });
122 })
123 ];
124 };
125 in
126 {
127 # NixOS configuration entrypoint
128 # Available through 'nixos-rebuild --flake .#hostname'
129 nixosConfigurations = {
130 moonlark = nixpkgs.lib.nixosSystem {
131 specialArgs = { inherit inputs outputs; };
132 modules = [
133 inputs.disko.nixosModules.disko
134 { disko.devices.disk.disk1.device = "/dev/vda"; }
135 agenix.nixosModules.default
136 unstable-overlays
137 ./machines/moonlark
138 nur.modules.nixos.default
139 ];
140 };
141 };
142
143 # Standalone home-manager configurations
144 # Available through 'home-manager --flake .#hostname'
145 homeConfigurations = {
146 "tacyon" = home-manager.lib.homeManagerConfiguration {
147 pkgs = nixpkgs.legacyPackages.aarch64-linux;
148 extraSpecialArgs = {
149 inherit inputs outputs;
150 nixpkgs-unstable = nixpkgs-unstable;
151 };
152 modules = [
153 ./machines/tacyon
154 unstable-overlays
155 ];
156 };
157
158 "nest" = home-manager.lib.homeManagerConfiguration {
159 pkgs = nixpkgs.legacyPackages.x86_64-linux;
160 extraSpecialArgs = {
161 inherit inputs outputs;
162 nixpkgs-unstable = nixpkgs-unstable;
163 };
164 modules = [
165 ./machines/nest
166 unstable-overlays
167 ];
168 };
169
170 "ember" = home-manager.lib.homeManagerConfiguration {
171 pkgs = nixpkgs.legacyPackages.x86_64-linux;
172 extraSpecialArgs = {
173 inherit inputs outputs;
174 nixpkgs-unstable = nixpkgs-unstable;
175 };
176 modules = [
177 ./machines/ember
178 unstable-overlays
179 ];
180 };
181 };
182
183 # Darwin configurations
184 # Available through 'darwin-rebuild switch --flake .#hostname'
185 darwinConfigurations = {
186 atalanta = nix-darwin.lib.darwinSystem {
187 system = "aarch64-darwin";
188 specialArgs = { inherit inputs outputs; };
189 modules = [
190 home-manager.darwinModules.home-manager
191 agenix.darwinModules.default
192 unstable-overlays
193 ./machines/atalanta
194 ];
195 };
196 };
197
198 formatter.x86_64-linux = nixpkgs.legacyPackages.x86_64-linux.nixfmt-tree;
199 formatter.aarch64-darwin = nixpkgs.legacyPackages.aarch64-darwin.nixfmt-tree;
200 };
201}