configs/zsh: add function to nixos-rebuild switch

This commit is contained in:
Aaron Bieber 2024-05-03 13:26:13 -06:00
parent 3649e5b21c
commit 7190c1220c
No known key found for this signature in database

View File

@ -45,6 +45,12 @@
go mod tidy
}
xin-update() {
SUDO_CMD=""
[[ $(id -u) == 0 ]] || SUDO_CMD="sudo"
$SUDO_CMD nixos-rebuild switch --flake github:qbit/xin --refresh |& nom
}
mkhash() {
nix hash to-sri --type sha256 $(nix-prefetch-url --type sha256 "$1")
}