summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorUrbain Vaes <urbain@vaes.uk>2018-11-25 13:54:19 +0100
committerUrbain Vaes <urbain@vaes.uk>2018-11-25 13:54:19 +0100
commitbcd3e89a1144f23a95f11e0243fedb2b7c1eaab9 (patch)
tree2428d4590f0d20bc4b5a584ff1f06b98ee43238e /bin
parent0a7b766e67fade604569fe9fe512fbb4f70c4d72 (diff)
Add binding to change keyboard
Diffstat (limited to 'bin')
-rwxr-xr-xbin/.local/bin/keyboard-us21
1 files changed, 21 insertions, 0 deletions
diff --git a/bin/.local/bin/keyboard-us b/bin/.local/bin/keyboard-us
new file mode 100755
index 0000000..8f93f66
--- /dev/null
+++ b/bin/.local/bin/keyboard-us
@@ -0,0 +1,21 @@
+#!/usr/bin/env bash
+
+# Key repeat rate
+xset r rate 400 50
+
+# Xcape settings
+killall -9 xcape
+
+# Set keyboard to US
+setxkbmap us
+
+# Make Caps_Lock (Control_L, Escape)
+xmodmap -e "clear Lock"
+xmodmap -e "keysym Caps_Lock = Control_L Control_L"
+xmodmap -e "add Control = Control_L"
+
+# Make space (Super_L, space)
+xmodmap -e "keysym space = Super_L"
+xmodmap -e "add mod4 = Super_L"
+xmodmap -e "keycode any = space"
+xcape -e 'Super_L=space'