{ flake, flakeInputs, path, userName, config, lib, utils, ... }:

with lib;

{
  config = {
    users.users.${userName} = {}; # Just make sure the user is created
    home-manager.users.${userName} = {};

    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
    };
  };
}