File tree 1 file changed +6
-6
lines changed
1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -9,22 +9,22 @@ if pgrep 'Coder Desktop'; then
9
9
touch $RUNNING_MARKER_FILE
10
10
fi
11
11
12
- vpnName =$( scutil --nc list | grep " com.coder.Coder-Desktop" | awk -F' "' ' {print $2}' )
12
+ vpn_name =$( scutil --nc list | grep " com.coder.Coder-Desktop" | awk -F' "' ' {print $2}' )
13
13
14
14
echo " Turning off VPN"
15
- if [[ -n " $vpnName " ]]; then
15
+ if [[ -n " $vpn_name " ]]; then
16
16
echo " CoderVPN found. Stopping..."
17
- if scutil --nc status " $vpnName " | grep -q " ^Connected$" ; then
17
+ if scutil --nc status " $vpn_name " | grep -q " ^Connected$" ; then
18
18
touch $VPN_MARKER_FILE
19
19
fi
20
- scutil --nc stop " $vpnName "
20
+ scutil --nc stop " $vpn_name "
21
21
22
22
# Wait for VPN to be disconnected
23
- while scutil --nc status " $vpnName " | grep -q " ^Connected$" ; do
23
+ while scutil --nc status " $vpn_name " | grep -q " ^Connected$" ; do
24
24
echo " Waiting for VPN to disconnect..."
25
25
sleep 1
26
26
done
27
- while scutil --nc status " $vpnName " | grep -q " ^Disconnecting$" ; do
27
+ while scutil --nc status " $vpn_name " | grep -q " ^Disconnecting$" ; do
28
28
echo " Waiting for VPN to complete disconnect..."
29
29
sleep 1
30
30
done
You can’t perform that action at this time.
0 commit comments