bash-scripts/wifitoggle.sh

11 lines
248 B
Bash
Raw Normal View History

2024-01-03 22:22:09 +01:00
#!/bin/sh
if [ $(nmcli radio wifi | awk '/led/ {print}') = 'enabled' ] ; then
nmcli radio wifi off
echo 'wifi off'
else
nmcli radio wifi on
# notify-send -i network-wireless-none "Wireless" "Wireless enabled"
echo 'wifi on'
fi