nixos-config/modules/nixos/users/tania/default.nix

37 lines
712 B
Nix

{
lib,
pkgs,
inputs,
namespace,
system,
target,
format,
virtual,
systems,
config,
...
}:
with lib;
with lib.${namespace}; let
username = "tania";
admin = false;
extraGroups = ["networkmanager" "touchscreen"];
trustedSshKeys = [];
cfg = config.${namespace}.users.${username};
in {
options.${namespace}.users.${username} = with types; {
enable = mkBoolOpt false "Enable ${username} user";
config = mkOpt types.attrs {} "Additional home manager config for ${username}";
};
config = mkUser {
inherit config;
inherit (cfg) enable;
homeConfig = cfg.config;
inherit username;
inherit admin;
inherit extraGroups;
inherit trustedSshKeys;
};
}