28 lines
421 B
Nix
28 lines
421 B
Nix
{
|
||
lib,
|
||
config,
|
||
...
|
||
}:
|
||
let
|
||
cfg = config.nix-config;
|
||
in
|
||
{
|
||
options = {
|
||
nix-config.userName = lib.mkOption {
|
||
type = lib.types.str;
|
||
default = "remy";
|
||
};
|
||
};
|
||
|
||
config = {
|
||
|
||
users.users.${cfg.userName} = {
|
||
isNormalUser = true;
|
||
extraGroups = [
|
||
"wheel" # Enable ‘sudo’ for the user.
|
||
# other groups are added as needed, eg. networkmanager
|
||
];
|
||
};
|
||
};
|
||
}
|