wrapper script
This commit is contained in:
parent
5c990ad496
commit
582986fba5
@ -1,2 +0,0 @@
|
||||
# this must be run before first bootstrap on new machine. IM SORRY
|
||||
nix-prefetch-url https://marq42.xyz/displaylink-580.zip
|
26
mix.sh
Executable file
26
mix.sh
Executable file
@ -0,0 +1,26 @@
|
||||
#!/bin/sh
|
||||
|
||||
fetch_dl_driver () {
|
||||
# this must be run before first bootstrap on new machine. IM SORRY
|
||||
file /nix/store/bsv1gnjqqivcbhgbs3cgd6d0i1yz66pj-displaylink-580.zip >&/dev/null ||
|
||||
nix-prefetch-url https://marq42.xyz/displaylink-580.zip
|
||||
}
|
||||
|
||||
hostname=$(cat /etc/hostname)
|
||||
|
||||
rebuild () {
|
||||
nixos-rebuild $1 --flake ./#$2
|
||||
}
|
||||
|
||||
case $1 in
|
||||
fetch)
|
||||
fetch_dl_driver
|
||||
;;
|
||||
switch)
|
||||
rebuild switch $hostname
|
||||
;;
|
||||
boot)
|
||||
rebuild boot $hostname
|
||||
;;
|
||||
|
||||
esac
|
Loading…
Reference in New Issue
Block a user