bin/soba/statusbar
#!/bin/sh while true do wifi="disconnected (0%)" if nmcli dev show wlan0 | grep GENERAL.STATE | grep -q connected; then wifiname="$(nmcli dev show wlan0 | grep 'GENERAL.CONNECTION' | sed 's|GENERAL.CONNECTION:[ ]*||g')" wifistrength="$(nmcli dev show wlan0 | awk '/GENERAL.STATE/ {print $2}')" wifi="$wifiname ($wifistrength%)" fi battery="$(cat /sys/class/power_supply/BAT1/capacity)%" time=$(date +"%A %Y-%m-%d %I:%M %p") time="$time $(date -u +"(🤖%H:%M UTC)")" printf "%s | %s | %s\n" "💓 ${wifi}" "🥤 ${battery}" "${time}" sleep 10 done