-
Notifications
You must be signed in to change notification settings - Fork 1
/
flake.nix
98 lines (84 loc) · 2.77 KB
/
flake.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
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
{
description = "Nix System Config";
nixConfig = {
extra-trusted-public-keys = "devenv.cachix.org-1:w1cLUi8dv3hnoSPGAuibQv+f9TZLr6cv/Hm9XgU50cw=";
extra-substituters = "https://devenv.cachix.org";
};
inputs = {
# Nixpkgs
nixpkgs.url = "github:nixos/nixpkgs/nixos-24.05";
nixpkgs-unstable.url = "github:nixos/nixpkgs/nixos-unstable";
# Home manager
home-manager.url = "github:nix-community/home-manager/release-24.05";
home-manager.inputs.nixpkgs.follows = "nixpkgs";
# Nix Darwin
darwin.url = "github:lnl7/nix-darwin";
darwin.inputs.nixpkgs.follows = "nixpkgs";
# Other Tools
flake-parts.url = "github:hercules-ci/flake-parts";
devenv.url = "github:cachix/devenv/latest";
# Adam's Flake
adamgoose.url = "github:adamgoose/nixpkgs/24.05";
adamgoose.inputs.nixpkgs.follows = "nixpkgs";
adamgoose.inputs.devenv.follows = "devenv";
};
outputs = inputs@{ nixpkgs, devenv, flake-parts, home-manager, ... }:
let
lib = import ./lib { inherit inputs; };
inherit (lib) mkHome mkDarwin mkSystem;
inherit (flake-parts.lib) mkFlake;
in
mkFlake { inherit inputs; } {
systems = [ "x86_64-linux" "aarch64-linux" "aarch64-darwin" "x86_64-darwin" ];
perSystem = { config, self', inputs', pkgs, system, ... }: {
packages = import ./pkgs { inherit pkgs; };
devShells = {
default = pkgs.mkShell {
nativeBuildInputs = [
inputs'.home-manager.packages.home-manager
];
};
};
};
flake = {
overlays.default = import ./overlay {
inherit nixpkgs;
};
homeConfigurations = {
bridge = mkHome {
name = "bridge";
username = "erik.jenks";
system = "aarch64-darwin";
features = [ "cli" "ide-full" "aws" "k8s" "iac" "ruby" ];
};
};
darwinConfigurations = {
bridge = mkDarwin {
name = "bridge";
username = "erik.jenks";
system = "aarch64-darwin";
features = [ "netskope" ];
homeFeatures = [ "cli" "ide-full" "aws" "k8s" "iac" "ruby" "wezterm" ];
};
};
homeConfigurations = {
home = mkHome {
name = "home";
username = "erikjenks";
system = "aarch64-darwin";
features = [ "cli" "ide-full" "aws" "k8s" ];
};
};
darwinConfigurations = {
home = mkDarwin {
name = "home";
username = "erikjenks";
system = "aarch64-darwin";
features = [ ];
homeFeatures = [ "cli" "ide-full" "aws" "k8s" "wezterm" ];
};
};
nixosConfigurations = { };
};
};
}