blob: 7034f17e23d8c516f0aabea5d8691a2a2b4b0a67 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
{ flake, flakeInputs, sources, path, userName, config, lib, utils, ... }:
with lib;
{
config = {
users.users.${userName} = {}; # Just make sure the user is created
home-manager.users.${userName} = let sysConfig = config; in { config, ... }: {
config._module.args = {
inherit sysConfig flake flakeInputs sources;
};
config.nix.settings = {
inherit (sysConfig.nix.settings) use-xdg-base-directories;
};
};
systemd.services."home-manager-${utils.escapeSystemdPath userName}" = lib.mkIf (!config.home-manager.enableSystemd) {
restartIfChanged = false; # only run once on startup, deploy to running system with deploy-rs
};
};
}
|