nixos/Justfile

19 lines
478 B
Makefile
Raw Normal View History

FLAKE_HOME := justfile_directory()
2025-01-24 21:29:55 +08:00
DEFAULT_SPECIALISATION := "default"
default:
@just --list
2025-01-24 21:29:55 +08:00
switch specialisation=DEFAULT_SPECIALISATION:
nh os switch {{ FLAKE_HOME }} {{ if specialisation == DEFAULT_SPECIALISATION { "-S" } else { "-s " + specialisation } }}
update:
2025-01-23 23:26:34 +08:00
nix flake update | spacer
2025-01-23 23:26:34 +08:00
push host target:
nixos-rebuild switch --flake {{ FLAKE_HOME }}#{{ host }} --target-host {{ target }} | spacer
alias s := switch
alias u := update
2025-01-23 23:26:34 +08:00
alias p := push