11 lines
357 B
Bash
Executable File
11 lines
357 B
Bash
Executable File
#!/bin/bash
|
|
|
|
# Show wifi 📶 and percent strength or 📡 if none.
|
|
# Show 🌐 if connected to ethernet or ❎ if none.
|
|
# Show 🔒 if a vpn connection is active
|
|
|
|
case "$(cat /sys/class/net/w*/operstate 2>/dev/null)" in
|
|
down) printf "^c#161616^^b#fd4285^\ue63e no wifi^d^" ;;
|
|
up) printf "\ue63e $(iw dev wlp3s0 info | awk '/ssid/ {print $2}')" ;;
|
|
esac
|