add userspace tools and passwdless sudo

This commit is contained in:
2025-11-07 15:05:42 -06:00
parent 1655c0a867
commit 7ef99c8dd1
3 changed files with 10 additions and 2 deletions

View File

@@ -26,7 +26,8 @@ echo "files:"
git status --short git status --short
read -rp "commit message: " commit_msg read -rp "commit message: " commit_msg
echo "rebuilding nixos with flake.nix..." echo "rebuilding nixos with flake.nix..."
if ! sudo nixos-rebuild switch --flake .#"$hostname" 2>&1 | tee "$logfile"; then #if ! sudo nixos-rebuild switch --flake .#"$hostname" 2>&1 | tee "$logfile"; then
if ! nh os switch 2>&1 | tee "$logfile"; then
echo "rebuild failed; exited with no commit" echo "rebuild failed; exited with no commit"
exit 1 exit 1
fi fi

View File

@@ -91,6 +91,10 @@
command = "/run/current-system/sw/bin/tailscale"; command = "/run/current-system/sw/bin/tailscale";
options = ["NOPASSWD"]; options = ["NOPASSWD"];
} }
{
command = "/etc/profiles/per-user/blake/bin/nh";
options = ["NOPASSWD"];
}
]; ];
} }
]; ];

View File

@@ -15,7 +15,10 @@ in {
config = lib.mkIf cfg.enable { config = lib.mkIf cfg.enable {
programs.${program} = { programs.${program} = {
enable = true; enable = true;
flake = "${home_dir}/.nix/flake.nix"; flake = "${home_dir}/.nix";
}; };
# add deps to userspace cause they are cool
home.packages = with pkgs; [nix-output-monitor nvd];
}; };
} }