From c285ddd9d16f0038da0c036882eef7be75e2aae0 Mon Sep 17 00:00:00 2001 From: Mitsuo Tokumori Date: Sat, 25 Nov 2023 15:50:08 -0500 Subject: Add helper scripts for dwmblocks --- local/bin/sb-input | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100755 local/bin/sb-input (limited to 'local/bin/sb-input') diff --git a/local/bin/sb-input b/local/bin/sb-input new file mode 100755 index 0000000..4fb1575 --- /dev/null +++ b/local/bin/sb-input @@ -0,0 +1,9 @@ +#!/bin/bash + +icon="🌐" +layout="$(setxkbmap -query | grep layout | awk '{print $2}')" + +# fcitx state, 0 for close, 1 for inactive, 2 for active +test $(fcitx5-remote) = 2 && layout="日本語" + +echo $icon$layout -- cgit v1.2.3