summaryrefslogtreecommitdiff
path: root/bin/extra/arr_hjkl
diff options
context:
space:
mode:
Diffstat (limited to 'bin/extra/arr_hjkl')
-rwxr-xr-xbin/extra/arr_hjkl17
1 files changed, 17 insertions, 0 deletions
diff --git a/bin/extra/arr_hjkl b/bin/extra/arr_hjkl
new file mode 100755
index 0000000..0ef542e
--- /dev/null
+++ b/bin/extra/arr_hjkl
@@ -0,0 +1,17 @@
+#!/bin/bash
+
+if [ "$(xmodmap -pke | grep ' = h')" ]
+then
+ xmodmap -e 'keycode 43 = Left'
+ xmodmap -e 'keycode 44 = Down Return'
+ xmodmap -e 'keycode 45 = Up'
+ xmodmap -e 'keycode 46 = Right'
+ dunstify "arr hjkl" "arrows <b>on</b>"
+else
+ export ARRKEYMODE="hjkl"
+ xmodmap -e 'keycode 43 = h'
+ xmodmap -e 'keycode 44 = j'
+ xmodmap -e 'keycode 45 = k'
+ xmodmap -e 'keycode 46 = l'
+ dunstify "arr hjkl" "arrows <b>off</b>"
+fi