Created
March 22, 2015 20:20
-
-
Save scemama/03e40e6b05d90e3dc3d8 to your computer and use it in GitHub Desktop.
Toggle keyboard layout
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
declare -A new_layout | |
new_layout["us"]="us_intl" | |
new_layout["us_intl"]="us" | |
cur_layout=$(setxkbmap -query | grep layout | cut -c13-) | |
setxkbmap -layout ${new_layout[$cur_layout]} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment