aboutsummaryrefslogtreecommitdiff
path: root/install
diff options
context:
space:
mode:
authorNathan Reiner <nathan@nathanreiner.xyz>2023-03-30 23:22:36 +0200
committerNathan Reiner <nathan@nathanreiner.xyz>2023-03-30 23:22:36 +0200
commitcd890066f9677d0af4ba3f722e0f1c06751adccc (patch)
tree2fa52b032c4028d5cd71ad0de37f962c838499ce /install
parent3d52b2129312d5a91bb9619d78e0578c98f31547 (diff)
make it look cool
Diffstat (limited to 'install')
-rwxr-xr-xinstall14
1 files changed, 10 insertions, 4 deletions
diff --git a/install b/install
index 5ee5f42..c8277d9 100755
--- a/install
+++ b/install
@@ -1,12 +1,18 @@
#!/bin/sh
-USB_UUID="$1"
+install_elk() {
+ cp ./elk.hook /etc/initcpio/hooks/elk
+ cp ./elk.install /etc/initcpio/install/elk
+ echo "Run 'mkinitcpio -P' to rebuild the initramfs"
+}
+
+[ "$1" = "elk" ] && install_elk && exit
+USB_UUID="$1"
[ -z "$USB_UUID" ] && echo ./install [UUID] && exit
sed ./keyusbctl -e "s/\[USB_UUID\]/${USB_UUID}/g" > /usr/local/sbin/keyusbctl
cp ./usb-unplug.rules /etc/udev/rules.d/
-cp ./elk.hook /etc/initcpio/hooks/elk
-cp ./elk.install /etc/initcpio/install/elk
chmod +x /usr/local/sbin/keyusbctl
-echo type 'udevadm control --reload' to reload the udev rules
+echo "Run 'udevadm control --reload' to reload the udev rules"
+install_elk