summaryrefslogtreecommitdiff
path: root/flake.nix
diff options
context:
space:
mode:
Diffstat (limited to 'flake.nix')
-rw-r--r--flake.nix99
1 files changed, 99 insertions, 0 deletions
diff --git a/flake.nix b/flake.nix
new file mode 100644
index 0000000..c5f593f
--- /dev/null
+++ b/flake.nix
@@ -0,0 +1,99 @@
1{
2 description = "Combined nix flake: darwin system (RyanMac) + standalone home-manager for Guix (ryan@linux)";
3
4 inputs = {
5 nixpkgs.url = "github:nixos/nixpkgs/nixpkgs-unstable";
6
7 darwin = {
8 url = "github:nix-darwin/nix-darwin/master";
9 inputs.nixpkgs.follows = "nixpkgs";
10 };
11 home-manager = {
12 url = "github:nix-community/home-manager";
13 inputs.nixpkgs.follows = "nixpkgs";
14 };
15
16 # Shared between darwin and linux
17 zen-browser = {
18 url = "github:0xc000022070/zen-browser-flake";
19 inputs = {
20 nixpkgs.follows = "nixpkgs";
21 home-manager.follows = "home-manager";
22 };
23 };
24
25 # Darwin-only
26 netbird-tui = {
27 url = "git+https://git.rschanz.org/netbird-tui-flake";
28 inputs.nixpkgs.follows = "nixpkgs";
29 };
30 nix-homebrew.url = "github:zhaofengli/nix-homebrew";
31 homebrew-core = {
32 url = "github:homebrew/homebrew-core";
33 flake = false;
34 };
35 homebrew-cask = {
36 url = "github:homebrew/homebrew-cask";
37 flake = false;
38 };
39 virby.url = "github:quinneden/virby-nix-darwin";
40 homebrew-netbird = {
41 url = "github:netbirdio/homebrew-tap";
42 flake = false;
43 };
44 homebrew-felixkratz = {
45 url = "github:FelixKratz/homebrew-formulae";
46 flake = false;
47 };
48
49 # Linux-only. hyprland/hyprlock/hypridle/hyprpicker/wpaperd/kanshi/pyprland
50 # all now ship in nixpkgs itself, so only the pieces nixpkgs doesn't carry
51 # need their own flake input:
52 nixgl = {
53 # Ryan's fork exists to patch Guix's mesa/OpenGL mismatch, unrelated to
54 # nixpkgs version - keep tracking it regardless of the nixpkgs bump.
55 url = "github:ryan77627/nixGL";
56 inputs.nixpkgs.follows = "nixpkgs";
57 };
58 clipboard-sync = {
59 url = "github:dnut/clipboard-sync";
60 inputs.nixpkgs.follows = "nixpkgs";
61 };
62 };
63
64 outputs = { nixpkgs, home-manager, ... }@inputs: {
65 darwinConfigurations."RyanMac" = inputs.darwin.lib.darwinSystem {
66 system = "aarch64-darwin";
67 specialArgs = { inherit inputs; };
68 modules = [
69 { nixpkgs.config.allowUnfree = true;
70 nixpkgs.overlays = [ inputs.netbird-tui.overlays.default ]; }
71 inputs.virby.darwinModules.default
72 ./hosts/RyanMac/configuration.nix
73 home-manager.darwinModules.home-manager
74 {
75 home-manager.useGlobalPkgs = true;
76 home-manager.useUserPackages = true;
77 home-manager.users.ryan = {
78 imports = [
79 inputs.zen-browser.homeModules.beta
80 ./users/ryan/common.nix
81 ./users/ryan/darwin.nix
82 ];
83 };
84 }
85 ];
86 };
87
88 homeConfigurations."ryan" = home-manager.lib.homeManagerConfiguration {
89 pkgs = nixpkgs.legacyPackages.x86_64-linux;
90 extraSpecialArgs = { inherit inputs; };
91 modules = [
92 { nixpkgs.config.allowUnfree = true; }
93 inputs.zen-browser.homeModules.beta
94 ./users/ryan/common.nix
95 ./users/ryan/linux.nix
96 ];
97 };
98 };
99}