Files
nix-config/Makefile
2023-06-13 01:07:25 +08:00

41 lines
998 B
Makefile

deploy:
sudo nixos-rebuild switch --flake .
debug:
sudo nixos-rebuild switch --flake . --show-trace --verbose
update:
nix flake update
history:
nix profile history --profile /nix/var/nix/profiles/system
gc:
# remove all generations older than 7 days
sudo nix profile wipe-history --profile /nix/var/nix/profiles/system --older-than 7d
# garbage collect all unused nix store entries
sudo nix store gc --debug
darwin-set-proxy:
sudo python3 scripts/darwin_set_proxy.py
darwin: darwin-set-proxy
nix build .#darwinConfigurations.harmonica.system \
--extra-experimental-features 'nix-command flakes'
./result/sw/bin/darwin-rebuild switch --flake .
darwin-debug: darwin-set-proxy
nix build .#darwinConfigurations.harmonica.system \
--show-trace --verbose \
--extra-experimental-features 'nix-command flakes'
./result/sw/bin/darwin-rebuild switch --flake . --show-trace --verbose
fmt:
# format the nix files in this repo
nix fmt
.PHONY: clean
clean:
rm -rf result