Skip to content

Instantly share code, notes, and snippets.

@valvallow
Created April 23, 2018 02:08
Show Gist options
  • Save valvallow/079cb52bc703955bc366d981665518e3 to your computer and use it in GitHub Desktop.
Save valvallow/079cb52bc703955bc366d981665518e3 to your computer and use it in GitHub Desktop.
#!/bin/sh
#
# it works on only cygwin.
#
if [ $# -eq 0 ]
then
netsh wlan show profiles | cut -d':' -f 2 | sed -e 's/^[ ]*//g' -e '1,8d'
else
netsh wlan show profiles name="$1" key=clear | nkf | grep -e 'SSID' | grep -e '名' | cut -d':' -f 2 | sed -e 's/"//g' -e 's/ //g'
netsh wlan show profiles name="$1" key=clear | nkf | grep '主要なコンテンツ' | cut -d':' -f 2 | sed 's/^[ ]*//g'
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment