use bash procsub
This commit is contained in:
parent
9bf90a1b72
commit
88477d8497
2 changed files with 4 additions and 6 deletions
|
@ -1,10 +1,8 @@
|
|||
#!/bin/sh
|
||||
#!/bin/bash
|
||||
|
||||
# Rerun the remaps script whenever a new input device is added.
|
||||
|
||||
while :; do
|
||||
udevadm monitor -u -t seat -s input -s usb | grep --line-buffer -m1 -P '[^un]bind'
|
||||
sleep 1
|
||||
remaps us:dvorak
|
||||
remaps
|
||||
grep -qP -m1 '[^un]bind.+\/[^:]+\(usb\)' <(udevadm monitor -u -t seat -s input -s usb)
|
||||
done
|
||||
|
||||
|
|
|
@ -8,4 +8,4 @@ setxkbmap -option caps:super,altwin:menu_win
|
|||
# When caps lock is pressed only once, treat it as escape.
|
||||
killall xcape 2>/dev/null ; xcape -e 'Super_L=Escape'
|
||||
# Turn off caps lock if on since there is no longer a key for it.
|
||||
xset -q | grep "Caps Lock:\s*on" && xdotool key Caps_Lock
|
||||
xset -q | grep -q "Caps Lock:\s*on" && xdotool key Caps_Lock
|
||||
|
|
Loading…
Reference in a new issue