{ pkgs, systemSettings, userSettings, ... }: let homePath = "/srv/panoptes"; repoURL = "https://gitea.john-stream.com/john/loki-nix"; repoBranch = "reorg"; in { nixpkgs.config.allowUnfree = true; programs.home-manager.enable = true; programs.git = { enable = true; extraConfig.credential.helper = "store --file ~/.git-credentials"; userName = "${userSettings.gitUserName}"; userEmail = "${userSettings.gitUserEmail}"; extraConfig.safe.directory = "${homePath}"; }; programs.bash.enable = true; programs.ssh.enable = true; home = { homeDirectory = "${homePath}"; packages = [ (pkgs.writeShellScriptBin "nfs" '' sudo nixos-rebuild switch --flake ${homePath}#${hostname} --impure '') (pkgs.writeShellScriptBin "init-panoptes" '' sudo -u git clone -b ${repoBranch} ${repoURL} /srv/panoptes '') git ]; }; systemd.user.startServices = "sd-switch"; }