chore: Changed xmobar look to be cleaner

This commit is contained in:
Afonso Franco 2022-10-31 21:00:11 +00:00
parent 9630e6b6f6
commit 40805cf02d
Signed by: afonso
SSH key fingerprint: SHA256:gkVPzsQQJzqi21ntQBV6pXTx4bYI53rFGI4XtvCpwd4
21 changed files with 900 additions and 150 deletions

View file

@ -0,0 +1,18 @@
#!/bin/bash
regex="([0-9A-Z]*:)+"
DEVICES=$(bluetoothctl devices)
ICON=""
COLOR="#696B71"
for DEVICE in $DEVICES
do
if [[ $DEVICE =~ $regex ]]; then
STATUS=$(bluetoothctl info $DEVICE | grep "Connected" | awk '{print $2}')
if [ $STATUS = "yes" ]; then
ICON=""
COLOR="#DFDFDF"
fi
fi
done
echo "<fc=$COLOR><fn=4>$ICON</fn></fc>"