Anmeldenamen in eine Variable ausgelagert.
This commit is contained in:
parent
5c817298f2
commit
85cb51f71e
4
v1.sh
4
v1.sh
@ -22,7 +22,7 @@ VPN_USERNAME="$2"
|
||||
# "security find-generic-password -g -a foo" where foo is an account
|
||||
# in your OSX Keychain, to avoid passwords stored in plain text
|
||||
GET_VPN_PASSWORD="security find-generic-password -g -a $VPN_USERNAME 2>&1 >/dev/null | cut -d'\"' -f2"
|
||||
|
||||
MEINE_MAIL="meine.mail@edu-up.de"
|
||||
# Command to determine if VPN is connected or disconnected
|
||||
VPN_CONNECTED="ifconfig | egrep -A1 'inet 172.[123][0-9]' |cut -d' ' -f2"
|
||||
# Command to run to disconnect VPN
|
||||
@ -63,6 +63,6 @@ if [ -n "$(eval "$VPN_CONNECTED")" ]; then
|
||||
else
|
||||
echo "VPN ❌ | color=red"
|
||||
echo '---'
|
||||
echo "Connect VPN | bash='$0' param1=connect param2=alessa.mielemeier@edu-up.de terminal=false refresh=true"
|
||||
echo "Connect VPN | bash='$0' param1=connect param2=$MEINE_MAIL terminal=false refresh=true"
|
||||
exit
|
||||
fi
|
||||
|
Loading…
Reference in New Issue
Block a user