refactor(modules): make username not hardcoded
This commit is contained in:
parent
9e17187b02
commit
fc7d95acfd
4 changed files with 15 additions and 4 deletions
|
@ -8,6 +8,7 @@
|
|||
let
|
||||
moduleName = "hmModules";
|
||||
cfg = config."${moduleName}";
|
||||
username = config.nixosModules.mainUser;
|
||||
in
|
||||
{
|
||||
imports = [
|
||||
|
@ -26,9 +27,9 @@ in
|
|||
useGlobalPkgs = true;
|
||||
useUserPackages = true;
|
||||
extraSpecialArgs = specialArgs;
|
||||
users.rafiq.home = {
|
||||
username = "rafiq";
|
||||
homeDirectory = "/home/rafiq";
|
||||
users."${username}".home = {
|
||||
username = username;
|
||||
homeDirectory = "/home/${username}";
|
||||
stateVersion = "25.05";
|
||||
};
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue