summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
Diffstat (limited to 'bin')
-rwxr-xr-xbin/extra/rebootfw11
-rwxr-xr-xbin/guiscripts/imgclip2
-rwxr-xr-xbin/menuscripts/mdsktp8
3 files changed, 12 insertions, 9 deletions
diff --git a/bin/extra/rebootfw b/bin/extra/rebootfw
new file mode 100755
index 0000000..53c6c00
--- /dev/null
+++ b/bin/extra/rebootfw
@@ -0,0 +1,11 @@
+#!/bin/sh
+
+printf "\x7\x0\x0\x0\x1\x0\x0\x0\x0\x0\x0\x0" |
+ doas tee "/sys/firmware/efi/efivars/OsIndications-8be4df61-93ca-11d2-aa0d-00e098032b8c"
+
+if [ "$(hostname)" = "spring" ]
+then
+ doas /usr/sbin/reboot
+else
+ reboot
+fi
diff --git a/bin/guiscripts/imgclip b/bin/guiscripts/imgclip
index eeac050..3b59cd1 100755
--- a/bin/guiscripts/imgclip
+++ b/bin/guiscripts/imgclip
@@ -1,5 +1,5 @@
#!/bin/sh
text="$(clipo | tesseract - stdout | sed '/^$/d')"
[ $? -gt 0 ] && exit 1
-choice="$(printf -- "-\n%s" "$text" | commander -cl)"
+choice="$(printf -- "-\n%s" "$text" | dmenu -c)"
[ "$choice" ] && printf "%s" "$text" | clipp
diff --git a/bin/menuscripts/mdsktp b/bin/menuscripts/mdsktp
deleted file mode 100755
index f07fb7b..0000000
--- a/bin/menuscripts/mdsktp
+++ /dev/null
@@ -1,8 +0,0 @@
-#!/bin/sh
-# Searches through .desktop files and prompt to launch them via dmenu
-
-choice="$(find ~/.local/share/applications -maxdepth 1 -type f -not -iname "wine-extension*" |
- awk '/\/[^.\/]+\.desktop/ {print $(NF-1)}' |
- commander -s -d -x -c)"
-[ "$choice" ] || exit 1
-gtk-launch "$choice"