blob: 89203c1084120f2f6bd9886e073964474fe06ed4 (
plain)
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
|
{
config,
lib,
pkgs,
inputs,
...
}:
let
cfg = config.borealis.users.seth;
inherit (pkgs.stdenv.hostPlatform) isDarwin isLinux;
in
{
options.borealis.users.seth = {
enable = lib.mkEnableOption "Seth's user & home configurations";
};
config = lib.mkMerge [
(lib.mkIf cfg.enable {
users.users.seth.shell = pkgs.fish;
programs.fish.enable = true;
home-manager.users.seth = {
imports = [ (inputs.self + "/users/seth") ];
seth = {
enable = true;
programs.fish.enable = true;
};
};
})
(lib.mkIf (cfg.enable && isDarwin) {
users.users.seth = {
home = lib.mkDefault "/Users/seth";
};
})
(lib.mkIf (cfg.enable && isLinux) {
users.users.seth = {
extraGroups = [ "wheel" ];
isNormalUser = true;
};
})
];
}
|