blob: 4219b67c7b1f54c35c21a0aafee3c01b24e817af (
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
|
{lib, config, pkgs, programs, environment, ...}:
let
cfg = config.main-user;
in
{
options.main-user = {
enable = lib.mkEnableOption "enable user module";
userName = lib.mkOption {
default = "master";
description = ''
username
'';
};
};
config = lib.mkIf config.main-user.enable {
programs.zsh.enable = true;
users.groups.plugdev = {};
users.users.${config.main-user.userName} = {
isNormalUser = true;
initialPassword = "password1324";
description = "Benjamin Chausse";
group = "wheel";
extraGroups = ["plugdev" "networkmanager" "docker" "mlocate"];
shell = pkgs.zsh;
};
environment.systemPackages = with pkgs; [
git
yadm
neovim
zsh
zsh-syntax-highlighting
];
};
}
|