Created
July 23, 2015 06:14
-
-
Save tysonclugg/390821d50e50ade64525 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
WLID=$( rfkill list | grep --only -P '[[:digit:]](?=: asus-wlan:)' ) | |
WLNET='Tyson Network' | |
rfkill list $WLID | |
set -x | |
#nmcli c down id 'Tyson Network' | |
rfkill block $WLID | |
rfkill unblock $WLID | |
[ "_$1" != "_down" ] && { | |
sleep 2 | |
#nmcli c up id 'Tyson Network' | |
ping -ac1 8.8.8.8 | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment