Fix showing ssid after kernel upgrade.

This commit is contained in:
Bartek Stalewski 2022-08-23 01:19:51 +02:00
parent b4d17a825e
commit 79fe75d0a4

View File

@ -5,6 +5,6 @@ case "$(cat /sys/class/net/w*/operstate 2>/dev/null)" in
down) printf "$icon <span background='#770000'>no wifi</span>" ;;
up)
[ -n "$(ip address show dev wlan0 | grep 'inet ')" ] \
&& printf "$icon $(iw dev wlan0 info | grep 'ssid ' | cut -d' ' -f2-)" \
&& printf "$icon $(iwgetid -r)" \
|| printf "$icon <span background='#770000'>no ip</span>"
esac