From ed5099ff571bda9392e255a6fdb8fceffdfd11a9 Mon Sep 17 00:00:00 2001 From: Amin Bandali Date: Sat, 7 Mar 2015 12:49:11 -0500 Subject: use XF86LaunchA for changing the keyboard layout --- sxhkd/.local/bin/toggle-layout | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100755 sxhkd/.local/bin/toggle-layout (limited to 'sxhkd/.local/bin') diff --git a/sxhkd/.local/bin/toggle-layout b/sxhkd/.local/bin/toggle-layout new file mode 100755 index 0000000..fcae134 --- /dev/null +++ b/sxhkd/.local/bin/toggle-layout @@ -0,0 +1,9 @@ +#!/bin/bash + +lang="$(setxkbmap -print | grep xkb_symbols | cut -d'+' -f 2)" + +if [ "$lang" = "us" ]; then + setxkbmap ir +else + setxkbmap us +fi \ No newline at end of file -- cgit v1.2.3-60-g2f50