Add CapsLock and NumLock indicators to the status bar
This commit is contained in:
parent
c403d9edd5
commit
03815a602f
1 changed files with 13 additions and 1 deletions
|
|
@ -7,6 +7,18 @@ else
|
|||
recs="📽${recordings}"
|
||||
fi
|
||||
|
||||
if [ "$(cat /sys/class/leds/input0::capslock/brightness)" = "1" ]; then
|
||||
capslock="𝗔"
|
||||
else
|
||||
capslock="𝗮"
|
||||
fi
|
||||
|
||||
if [ "$(cat /sys/class/leds/input0::numlock/brightness)" = "1" ]; then
|
||||
numlock="🔢"
|
||||
else
|
||||
numlock="⮔"
|
||||
fi
|
||||
|
||||
touchpad=$(swaymsg -t get_inputs | jq -r '[.[] | select(.type == "touchpad")][0] | .libinput.send_events')
|
||||
if [ "${touchpad}" = "enabled" ]; then
|
||||
touchpad_active="✅"
|
||||
|
|
@ -97,4 +109,4 @@ case "${battery_state}" in
|
|||
;;
|
||||
esac
|
||||
|
||||
echo "${recs} 🕹️${touchpad_active} 📆${today} ${clock_face}${now} ${mike_symbol}${mike_volume}% ${audio_symbol}${audio_volume}% ${battery_symbol}${battery}%"
|
||||
echo "${numlock}${capslock} ${recs} 🕹️${touchpad_active} 📆${today} ${clock_face}${now} ${mike_symbol}${mike_volume}% ${audio_symbol}${audio_volume}% ${battery_symbol}${battery}%"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue