voidrice/.scripts/statusbar/i3wifi

10 lines
213 B
Text
Raw Normal View History

2018-11-04 23:56:54 +00:00
#!/bin/sh
2018-08-02 00:38:48 +00:00
case $BLOCK_BUTTON in
2018-11-04 23:56:54 +00:00
1) $TERMINAL -e nmtui ;;
2018-08-02 00:38:48 +00:00
esac
2018-11-04 23:56:54 +00:00
[ "$(cat /sys/class/net/w*/operstate)" = 'down' ] && echo 📡 && exit
2018-08-02 00:38:48 +00:00
2018-11-04 23:56:54 +00:00
grep ^w /proc/net/wireless | awk '{ print "📶", int($3 * 100 / 70) "%" }'