mirror of
https://github.com/lightly-toasted/nix-config.git
synced 2026-01-31 12:40:24 +00:00
Compare commits
No commits in common. "3c314ad5bd22b9d9e0e006d38a83db529282578c" and "f2a6dee6697016b82d44493d39f0128d9a267f07" have entirely different histories.
3c314ad5bd
...
f2a6dee669
6 changed files with 13 additions and 26 deletions
|
|
@ -11,8 +11,8 @@ My personal NixOS and home-manager configurations.
|
|||
```sh
|
||||
nix develop
|
||||
|
||||
just nixos # Rebuild and switch the current NixOS system on this host
|
||||
just home # Apply Home Manager configuration for the current user
|
||||
just vps # Rebuild and switch NixOS on the remote VPS
|
||||
just deploy-nixos # Rebuild and switch the current NixOS system on this host
|
||||
just deploy-home # Apply Home Manager configuration for the current user
|
||||
just deploy-vps # Rebuild and switch NixOS on the remote VPS
|
||||
```
|
||||
|
||||
|
|
|
|||
|
|
@ -90,7 +90,6 @@
|
|||
pkgs.git
|
||||
pkgs.git-crypt
|
||||
pkgs.just
|
||||
pkgs.nh
|
||||
];
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -10,6 +10,5 @@
|
|||
./ydotool.nix
|
||||
./steam.nix
|
||||
./nix-ld.nix
|
||||
./nh.nix
|
||||
];
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,8 +0,0 @@
|
|||
{
|
||||
programs.nh = {
|
||||
enable = true;
|
||||
clean.enable = true;
|
||||
clean.extraArgs = "--keep-since 7d --keep 3";
|
||||
flake = "/home/toast/nix-config";
|
||||
};
|
||||
}
|
||||
21
justfile
21
justfile
|
|
@ -3,20 +3,19 @@
|
|||
default:
|
||||
@just --list
|
||||
|
||||
_check-nh:
|
||||
@command -v nh > /dev/null 2>&1 || echo "nh is not in PATH. Run 'nix develop' first."
|
||||
deploy-nixos:
|
||||
sudo nixos-rebuild switch --flake .#$(hostname)
|
||||
|
||||
nixos: _check-nh
|
||||
nh os switch .
|
||||
deploy-vps:
|
||||
nixos-rebuild switch --flake .#vps --target-host root@vps
|
||||
|
||||
vps: _check-nh
|
||||
nh os switch . -H vps --target-host root@vps
|
||||
|
||||
home: _check-nh
|
||||
nh home switch .
|
||||
deploy-home:
|
||||
home-manager switch --flake .#$USER@$(hostname)
|
||||
|
||||
update:
|
||||
nix flake update --commit-lock-file
|
||||
|
||||
gc: _check-nh
|
||||
nh clean all --keep-since 7d
|
||||
gc:
|
||||
nix-collect-garbage -d
|
||||
nix-collect-garbage --delete-older-than 7d
|
||||
nix-store --gc
|
||||
|
|
|
|||
|
|
@ -7,7 +7,5 @@ pkgs.mkShell {
|
|||
git
|
||||
sops
|
||||
git-crypt
|
||||
just
|
||||
nh
|
||||
];
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue