Add justfile
This commit is contained in:
parent
a8fff66029
commit
877845ad1a
4 changed files with 38 additions and 63 deletions
36
justfile
Normal file
36
justfile
Normal file
|
@ -0,0 +1,36 @@
|
|||
alias b := build
|
||||
alias s := switch
|
||||
alias t := test
|
||||
alias u := update
|
||||
|
||||
_default:
|
||||
just --list
|
||||
|
||||
build *args:
|
||||
@just _nixos build {{ args }}
|
||||
|
||||
check:
|
||||
nix flake check
|
||||
|
||||
clean:
|
||||
nix store optimise --verbose
|
||||
nix store gc --verbose
|
||||
|
||||
collect-garbage:
|
||||
nix-collect-garbage -d
|
||||
sudo nix-collect-garbage -d
|
||||
|
||||
format:
|
||||
nix fmt flake.nix hosts modules
|
||||
|
||||
switch *args:
|
||||
@just _nixos switch {{ args }}
|
||||
|
||||
test *args:
|
||||
@just _nixos test {{ args }}
|
||||
|
||||
update:
|
||||
nix flake update
|
||||
|
||||
_nixos command *args:
|
||||
sudo nixos-rebuild {{ command }} --flake . {{ args }}
|
Loading…
Add table
Add a link
Reference in a new issue