Skip to content

Commit 379396c

Browse files
committed
Fix justfile switch
1 parent 537aead commit 379396c

1 file changed

Lines changed: 2 additions & 3 deletions

File tree

justfile

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,13 @@ default: switch
44
# Substitute work laptop hostname if necessary
55
hostname := `[ "$(hostname | cut -d "." -f 1)" = "RL-17745394" ] && echo "Petrichor" || hostname | cut -d "." -f 1`
66

7-
# TODO: `nh` can't specify the flake attribute?
87
[macos]
98
switch host=hostname:
10-
sudo darwin-rebuild switch --flake .#{{host}}
9+
nh darwin switch .#darwinConfigurations.{{host}}
1110

1211
[linux]
1312
switch host=hostname:
14-
nh os switch .#{{host}}
13+
nh os switch .#nixosConfigurations.{{host}}
1514

1615
update:
1716
nix flake update --commit-lock-file

0 commit comments

Comments
 (0)