QR wifi image creator
This commit is contained in:
15
.functions/qr-wifi.sh
Normal file
15
.functions/qr-wifi.sh
Normal file
@@ -0,0 +1,15 @@
|
||||
#!/bin/bash
|
||||
|
||||
qr-wifi(){
|
||||
#create a qr-code for wifi access
|
||||
# $1 SSID
|
||||
# $2 Preshared key
|
||||
# #3 (optional) png output file, default wifi.png
|
||||
|
||||
local outputfile="${3:-wifi.png}"
|
||||
local ssid="$1"
|
||||
local pass="$2"
|
||||
|
||||
qrencode -o "$outputfile" "WIFI:T:WPA;S:${ssid};P:${pass};;"
|
||||
|
||||
}
|
Reference in New Issue
Block a user