Created
March 12, 2020 00:54
-
-
Save 0az/1477849d0e6c93398ae495e4160de547 to your computer and use it in GitHub Desktop.
Print the current wireless network SSID to stdout
This file contains 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 | |
airport_ssid() { | |
/System/Library/PrivateFrameworks/Apple80211.framework/Resources/airport -I \ | |
| sed -nE 's/^[[:space:]]+[[:<:]]SSID:[[:space:]]+//p' | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment