justfile | remove call to nixfmt for most cases
This commit is contained in:
parent
aa4e620fc4
commit
cc1b9f25e8
1 changed files with 4 additions and 9 deletions
13
justfile
13
justfile
|
|
@ -8,13 +8,11 @@ test hostname=(HOSTNAME):
|
|||
|
||||
# Apply config on hostname
|
||||
switch hostname=(HOSTNAME):
|
||||
@nixfmt . &> nixos-switch.log || ( cat nixos-switch.log && false )
|
||||
@rm -f nixos-switch.log
|
||||
@colmena --impure apply --on {{hostname}}
|
||||
|
||||
# Apply config on hostname at next reboot
|
||||
boot:
|
||||
@nixfmt . &> nixos-switch.log || ( cat nixos-switch.log && false )
|
||||
@rm -f nixos-switch.log
|
||||
@doas nixos-rebuild switch --impure --flake .#{{HOSTNAME}}
|
||||
|
||||
|
|
@ -25,21 +23,18 @@ world:
|
|||
|
||||
# Build and install the workstations
|
||||
workstation:
|
||||
@nixfmt . &> nixos-switch.log || ( cat nixos-switch.log && false )
|
||||
@rm -f nixos-switch.log
|
||||
@colmena --impure exec --on @workstation "locate home-manager-backup | sort -u | xargs rm -f"
|
||||
@colmena --impure apply --on @workstation
|
||||
|
||||
# Build and install the servers
|
||||
server:
|
||||
@nixfmt . &> nixos-switch.log || ( cat nixos-switch.log && false )
|
||||
@rm -f nixos-switch.log
|
||||
@colmena --impure exec --on @server "locate home-manager-backup | sort -u | xargs rm -f"
|
||||
@colmena --impure apply --on @server
|
||||
|
||||
# Build and install the webhosts
|
||||
web:
|
||||
@nixfmt . &> nixos-switch.log || ( cat nixos-switch.log && false )
|
||||
@rm -f nixos-switch.log
|
||||
@colmena --impure exec --on @web "locate home-manager-backup | sort -u | xargs rm -f"
|
||||
@colmena --impure apply --on @web
|
||||
|
|
@ -47,7 +42,6 @@ web:
|
|||
# Build and run a vm FIXME
|
||||
vm hostname=(HOSTNAME):
|
||||
@doas rm -f result
|
||||
@nixfmt . &> nixos-switch.log || ( cat nixos-switch.log && false )
|
||||
@rm -f nixos-switch.log
|
||||
@echo Running iso build
|
||||
@nixos-rebuild build-vm --impure --flake .#{{hostname}}
|
||||
|
|
@ -55,13 +49,11 @@ vm hostname=(HOSTNAME):
|
|||
result/bin/run-{{hostname}}-vm
|
||||
|
||||
buildiso hostname:
|
||||
@nixfmt . &> nixos-switch.log || ( cat nixos-switch.log && false )
|
||||
@rm -f nixos-switch.log result
|
||||
@echo Running iso build
|
||||
@NIXPKGS_ALLOW_UNFREE=1 nix run --impure nixpkgs#nixos-generators -- -f iso --flake .#{{hostname}} --system x86_64-linux -o ./{{hostname}}.sd &> nixos-switch.log || ( cat nixos-switch.log && false )
|
||||
|
||||
buildsd hostname:
|
||||
@nixfmt . &> nixos-switch.log || ( cat nixos-switch.log && false )
|
||||
@rm -f nixos-switch.log result
|
||||
@echo Running sd build
|
||||
@doas nix run nixpkgs#nixos-generators -- -f sd-aarch64 --flake .#{{hostname}} --system aarch64-linux -o ./{{hostname}}.sd &> nixos-switch.log || ( cat nixos-switch.log && false )
|
||||
|
|
@ -119,10 +111,13 @@ ci:
|
|||
|
||||
# Go old school
|
||||
oldschool:
|
||||
@nixfmt . &> nixos-switch.log || ( cat nixos-switch.log && false )
|
||||
@rm -f nixos-switch.log
|
||||
@doas nixos-rebuild switch --impure --flake .#{{HOSTNAME}}
|
||||
|
||||
# Reboot on hostname
|
||||
reboot hostname=(HOSTNAME):
|
||||
@colmena --impure exec --on {{hostname}} "doas reboot"
|
||||
|
||||
# Format the code
|
||||
format:
|
||||
@nixfmt . &> nixos-switch.log || ( cat nixos-switch.log && false )
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue