aboutsummaryrefslogtreecommitdiff
path: root/dotfiles/.local/bin/swaykbd
diff options
context:
space:
mode:
authorYaroslav <contact@yaroslavps.com>2020-04-06 02:30:09 +0300
committerYaroslav <contact@yaroslavps.com>2020-04-06 02:30:09 +0300
commitcbfd974f652a12c601a95ea6d364549f45cb87e3 (patch)
tree06ad8bd90f653102065d4028d64a274f6d9bcd39 /dotfiles/.local/bin/swaykbd
parente351037f1e0f48a2a1602a07d376980c9e595091 (diff)
downloadswayrice-cbfd974f652a12c601a95ea6d364549f45cb87e3.tar.gz
swayrice-cbfd974f652a12c601a95ea6d364549f45cb87e3.zip
improved script for pacman package download cron job; waybar improvements
Diffstat (limited to 'dotfiles/.local/bin/swaykbd')
-rwxr-xr-xdotfiles/.local/bin/swaykbd8
1 files changed, 3 insertions, 5 deletions
diff --git a/dotfiles/.local/bin/swaykbd b/dotfiles/.local/bin/swaykbd
index d90f78c..2ec42c3 100755
--- a/dotfiles/.local/bin/swaykbd
+++ b/dotfiles/.local/bin/swaykbd
@@ -3,7 +3,7 @@
swaymsg -r -t get_inputs | \
grep "xkb_active_layout_name" | \
awk -F '"' '{print $4}' | \
- sed 's/English (US)/🇺🇸 English/g;s/Spanish/🇲🇽 Español/g;s/Russian/🇷🇺 Русский/g' | head -1
+ sed --unbuffered 's/English (US)/🇺🇸 EN/g;s/Spanish/🇲🇽 ES/g;s/Russian/🇷🇺 RU/g'| head -1
swaymsg \
--type subscribe \
@@ -14,8 +14,6 @@ swaymsg \
--raw-output \
--unbuffered \ '
select(.change == "xkb_layout") |
- .input.xkb_active_layout_name |
- sub(" \\(US\\)"; "")
- ' | \
- sed --unbuffered 's/English/🇺🇸 English/g;s/Spanish/🇲🇽 Español/g;s/Russian/🇷🇺 Русский/g'
+ .input.xkb_active_layout_name' | \
+ sed --unbuffered 's/English (US)/🇺🇸 EN/g;s/Spanish/🇲🇽 ES/g;s/Russian/🇷🇺 RU/g'