tangled
alpha
login
or
join now
bwc9876.dev
/
nixos-config
1
fork
atom
Flake for my NixOS devices
1
fork
atom
overview
issues
pulls
pipelines
just: tweaks
Spoonbaker
4 months ago
420e53f3
b011e9c5
+15
-5
1 changed file
expand all
collapse all
unified
split
justfile
+15
-5
justfile
···
1
1
+
GARGS := if env("SPOON_PATH", "") != "" {"--override-input spoon \"$SPOON_PATH\""} else { "" }
2
2
+
1
3
_default:
2
4
@{{ just_executable() }} --list --unsorted --justfile {{ justfile() }}
3
5
···
11
13
alias b := build
12
14
# b: build the configuration
13
15
build:
14
14
-
nh os build .
16
16
+
nh os build . {{ GARGS }}
15
17
16
18
[private]
17
19
alias bt := boot
18
20
# bt: make the configuration the boot default without activating it
19
21
boot:
20
20
-
nh os boot .
22
22
+
nh os boot . {{ GARGS }}
21
23
22
24
[private]
23
25
alias s := switch
24
26
# s: activate configuration & add to boot menu
25
27
switch:
26
26
-
nh os switch --ask .
28
28
+
nh os switch --ask . {{ GARGS }}
27
29
28
30
[private]
29
31
alias c := check
30
32
# c: run all checks for the current system
31
33
check *ARGS:
32
32
-
nix flake check --show-trace {{ if env("SPOON_PATH", "") != "" {"--override-input spoon \"$SPOON_PATH\" --no-build"} else { "" } }} {{ ARGS }} --log-format internal-json -v |& nom --json
34
34
+
nix flake check --show-trace {{ GARGS }} {{ ARGS }} --log-format internal-json -v |& nom --json
35
35
+
36
36
+
[private]
37
37
+
alias d := deploy
38
38
+
# d: deploy the given host
39
39
+
deploy ACTION="switch" HOST="black-mesa":
40
40
+
NIX_SSHOPTS="-p 8069" nixos-rebuild {{ ACTION }} --flake .#{{ HOST }} --build-host {{ HOST }}.lan --target-host {{ HOST }}.lan --sudo --override-input spoon "git+https://codeberg.org/spoonbaker/mono?ref=devel" --refresh
33
41
34
42
[private]
35
43
alias f := format
···
41
49
alias r := repl
42
50
# r: start a debugging repl
43
51
repl:
44
44
-
nix repl .#repl
52
52
+
nix repl {{ GARGS }} .#repl
45
53
46
54
[private]
47
55
alias gc := garbage-collect
···
53
61
alias iso := generate-iso
54
62
generate-iso:
55
63
nom build .#nixosConfigurations.installer.config.system.build.isoImage
64
64
+
65
65
+