mirror of
https://github.com/LnL7/nix-darwin.git
synced 2024-12-14 11:57:34 +00:00
users: set default
for users.users.<user>.name
This commit is contained in:
parent
2788e4fa98
commit
5b873c48ac
2 changed files with 8 additions and 18 deletions
|
@ -1,11 +1,12 @@
|
||||||
{ name, lib, ... }:
|
{ name, lib, ... }:
|
||||||
|
|
||||||
with lib;
|
|
||||||
|
|
||||||
{
|
{
|
||||||
options = {
|
options = let
|
||||||
|
inherit (lib) mkOption types;
|
||||||
|
in {
|
||||||
name = mkOption {
|
name = mkOption {
|
||||||
type = types.str;
|
type = types.str;
|
||||||
|
default = name;
|
||||||
description = ''
|
description = ''
|
||||||
The group's name. If undefined, the name of the attribute set
|
The group's name. If undefined, the name of the attribute set
|
||||||
will be used.
|
will be used.
|
||||||
|
@ -29,10 +30,4 @@ with lib;
|
||||||
description = "The group's description.";
|
description = "The group's description.";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
config = {
|
|
||||||
|
|
||||||
name = mkDefault name;
|
|
||||||
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,11 +1,12 @@
|
||||||
{ name, lib, ... }:
|
{ name, lib, ... }:
|
||||||
|
|
||||||
with lib;
|
|
||||||
|
|
||||||
{
|
{
|
||||||
options = {
|
options = let
|
||||||
|
inherit (lib) literalExpression mkOption types;
|
||||||
|
in {
|
||||||
name = mkOption {
|
name = mkOption {
|
||||||
type = types.str;
|
type = types.str;
|
||||||
|
default = name;
|
||||||
description = ''
|
description = ''
|
||||||
The name of the user account. If undefined, the name of the
|
The name of the user account. If undefined, the name of the
|
||||||
attribute set will be used.
|
attribute set will be used.
|
||||||
|
@ -75,10 +76,4 @@ with lib;
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
config = {
|
|
||||||
|
|
||||||
name = mkDefault name;
|
|
||||||
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue