summaryrefslogtreecommitdiff
path: root/.local/bin/layouthandler
blob: 0bd8d33a8cff0bd0ef8410cd2f61b4ed85be6f21 (plain)
1
2
3
4
5
6
7
8
9
10
#!/bin/sh

layout="$(setxkbmap -query | awk '$1 ~ /layout/ { print $2 }')"

case $layout in
  en_US)
    setxkbmap -layout se ;;
  *)
    setxkbmap -layout en_US
esac