[bin/qrwifi] Show overview of info in QR code
This commit is contained in:
parent
b83a91e303
commit
35b6c40c35
1 changed files with 3 additions and 6 deletions
|
@ -30,14 +30,11 @@ if [ -z "$pw" ]; then
|
||||||
echo "Couldn't find password for network \`$ssid\`"
|
echo "Couldn't find password for network \`$ssid\`"
|
||||||
echo "Use $0 <ssid> <password>" to share a specific SSID and password
|
echo "Use $0 <ssid> <password>" to share a specific SSID and password
|
||||||
exit 1
|
exit 1
|
||||||
else
|
|
||||||
echo "Sharing network \`$ssid\`"
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ -z "$ssid" ] || [ -z "$pw" ]; then
|
echo "$(tput bold)SSID$(tput sgr0) $ssid"
|
||||||
echo "Missing SSID or password"
|
echo "$(tput bold)Password$(tput sgr0) $pw"
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
if printf '%s' "$pw" | grep -qF ';'; then
|
if printf '%s' "$pw" | grep -qF ';'; then
|
||||||
echo "Password contains ;, I didn't look up how to handle that case"
|
echo "Password contains ;, I didn't look up how to handle that case"
|
||||||
exit 1
|
exit 1
|
||||||
|
|
Loading…
Reference in a new issue