-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathflake.nix
More file actions
71 lines (62 loc) · 2.32 KB
/
Copy pathflake.nix
File metadata and controls
71 lines (62 loc) · 2.32 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
{
description = "My Personal Home Manager Configuration";
inputs = {
nixpkgs.url = "github:nixos/nixpkgs/nixos-25.11";
nixpkgs-unstable.url = "github:nixos/nixpkgs/nixos-unstable";
nixpkgs-master.url = "github:nixos/nixpkgs/master";
home-manager.url = "github:nix-community/home-manager/release-25.11";
home-manager.inputs.nixpkgs.follows = "nixpkgs";
sops-nix.url = "github:mic92/sops-nix";
sops-nix.inputs.nixpkgs.follows = "nixpkgs";
bash-it = {
url = "github:Bash-it/bash-it";
flake = false;
};
};
outputs = { self, nixpkgs, nixpkgs-unstable, nixpkgs-master, home-manager, sops-nix, bash-it, ... }@inputs:
let
mkHome = { system, configPath }:
let
config = { allowUnfree = true; };
pkgs = import nixpkgs { inherit system config; };
pkgsUnstable = import nixpkgs-unstable { inherit system config; };
pkgsMaster = import nixpkgs-master { inherit system config; };
lib = pkgs.lib;
pkgsPr = lib.mapAttrs' (name: value: {
name = lib.removePrefix "nixpkgs-pr-" name;
value = import value { inherit system config; };
}) (lib.filterAttrs (name: _: lib.hasPrefix "nixpkgs-pr-" name) inputs);
in
home-manager.lib.homeManagerConfiguration {
inherit pkgs;
extraSpecialArgs = {
inherit sops-nix inputs pkgsUnstable pkgsMaster pkgsPr;
};
modules = [
configPath
sops-nix.homeManagerModules.sops
];
};
in
{
homeConfigurations = {
"brantes@x86_64.wsl.desktop" = mkHome {
system = "x86_64-linux";
configPath = ./machines/x86_64/wsl/desktop/default.nix;
};
# Generic Linux target (useful for CI/CD on ubuntu-latest)
"brantes@x86_64.linux.desktop" = mkHome {
system = "x86_64-linux";
configPath = ./machines/x86_64/linux/desktop/default.nix;
};
"brantes@aarch64.android.smartphone" = mkHome {
system = "aarch64-linux";
configPath = ./machines/aarch64/android/smartphone/default.nix;
};
"brantes@aarch64.android.tablet" = mkHome {
system = "aarch64-linux";
configPath = ./machines/aarch64/android/tablet/default.nix;
};
};
};
}