summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Voss <mail@thomasvoss.com> 2023-11-20 23:59:23 +0100
committerThomas Voss <mail@thomasvoss.com> 2023-11-20 23:59:23 +0100
commitdd96f6351926d767ec06ca2d3ad73d6297150a30 (patch)
treec9002c84d934be6d7116cd315564d70c72cc07c7
parent5f0c91f9675eec5854d68cacafad75efa71c65f5 (diff)
eww: Ignore non-laptop keyboards
-rwxr-xr-x.config/eww/scripts/keymap-listener3
1 files changed, 2 insertions, 1 deletions
diff --git a/.config/eww/scripts/keymap-listener b/.config/eww/scripts/keymap-listener
index 364375d..82304b2 100755
--- a/.config/eww/scripts/keymap-listener
+++ b/.config/eww/scripts/keymap-listener
@@ -1,6 +1,7 @@
#!/bin/sh
readonly IPC=/tmp/hypr/$HYPRLAND_INSTANCE_SIGNATURE/.socket2.sock
+readonly KBD=at-translated-set-2-keyboard
hyprctl devices -j | jq -r '.keyboards[-1].active_keymap'
-socat -u UNIX-CONNECT:"$IPC" - | sed -En 's/^activelayout>>[^,]+,//p'
+socat -u UNIX-CONNECT:"$IPC" - | sed -En "s/^activelayout>>$KBD,//p"