blob: d21690ba3e144bfa33a35bc85ceeb4d007ac3238 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
#!/usr/local/bin/dash
xset r rate 200 150
setxkbmap -layout us,fr -option grp:alt_shift_toggle
if ! xrandr | grep 'HDMI-1 connected' >/dev/null 2>&1; then
if ! xrandr | grep 'VGA-1 connected' >/dev/null 2>&1; then
echo
setxkbmap -option ctrl:swapcaps
xmodmap -e "remove Lock = Caps_Lock"
xmodmap -e 'keycode 37 = Escape'
# setxkbmap -option caps:escape
# xmodmap -e "remove Control = Control_L"
# xmodmap -e "keysym Control_L = Caps_Lock"
# xmodmap -e "keysym Caps_Lock = Control_L"
# xmodmap -e "add Lock = Caps_Lock"
# xmodmap -e "add Control = Control_L"
fi
else
setxkbmap -option caps:swapescape
fi
notify-send -u low -t 2000 'kb' ' Keyboard set'
# vim: filetype=sh
|