Skip to content

Instantly share code, notes, and snippets.

@altmas5
Created November 4, 2012 00:01
Show Gist options
  • Save altmas5/4009391 to your computer and use it in GitHub Desktop.
Save altmas5/4009391 to your computer and use it in GitHub Desktop.
switch keybord layout
#!/bin/bash
current=`setxkbmap -query| grep layout| awk '{print $2}'`
echo $current;
if [ $current == "us" ]
then
# echo "Esta en gringo"
setxkbmap es
else
if [ $current == "es" ]
then
# echo "Castellano tio"
setxkbmap us
fi
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment