pid test 12
This commit is contained in:
parent
e4cf040c49
commit
cc6ebb3206
5
wire_g
5
wire_g
@ -218,6 +218,7 @@ connect(){
|
|||||||
then
|
then
|
||||||
nmcli con mod $selection connection.autoconnect no
|
nmcli con mod $selection connection.autoconnect no
|
||||||
wg_notify
|
wg_notify
|
||||||
|
wire_g
|
||||||
fi }
|
fi }
|
||||||
|
|
||||||
# function end
|
# function end
|
||||||
@ -246,12 +247,12 @@ if selection=$(yad --no-klick --list --center \
|
|||||||
nmcli connection up $selection &> ${wg_wdir}.tmp.txt
|
nmcli connection up $selection &> ${wg_wdir}.tmp.txt
|
||||||
connect
|
connect
|
||||||
pid=$(ps aux | grep yad | grep -v grep | awk '{print $2}')
|
pid=$(ps aux | grep yad | grep -v grep | awk '{print $2}')
|
||||||
kill $pid && wire_g
|
kill $pid
|
||||||
else
|
else
|
||||||
nmcli connection up $selection &> ${wg_wdir}.tmp.txt
|
nmcli connection up $selection &> ${wg_wdir}.tmp.txt
|
||||||
connect
|
connect
|
||||||
pid=$(ps aux | grep yad | grep -v grep | awk '{print $2}')
|
pid=$(ps aux | grep yad | grep -v grep | awk '{print $2}')
|
||||||
kill $pid && wire_g
|
kill $pid
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user