this repo has no description
1# -*- sh -*-
2
3# NixOS and home-manager update commands.
4# System rebuild is for kernel, drivers, services, etc.
5# Home rebuild is for user packages, dotfiles, and settings -- fast, no sudo.
6
7update-system() {
8 sudo nixos-rebuild switch --flake ~/etc#parsec "$@"
9}
10
11update-home() {
12 if command -v home-manager &>/dev/null; then
13 home-manager switch --flake ~/etc "$@"
14 else
15 echo "bootstrapping home-manager via nix run..."
16 nix run home-manager -- switch --flake ~/etc "$@"
17 fi
18}
19
20restic-backblaze() {
21 sudo env $(sudo cat /etc/secrets/restic-env | xargs) \
22 restic -r b2:accidental-cc-parsec-backups \
23 --password-file /etc/secrets/restic-password "$@"
24}
25
26nix_setup() { }
27nix_setup "$@"