korrektur test pid 8

This commit is contained in:
Désiré Werner Menrath 2023-11-11 19:23:52 +01:00
parent e354c1c04e
commit ab365e2ed7

4
wire_g
View File

@ -231,7 +231,7 @@ if selection=$(yad --no-klick --list --center \
--text=$"<b>Activ Tunnel: </b> <span color='#0fad0a'><b>$active</b></span> --text=$"<b>Activ Tunnel: </b> <span color='#0fad0a'><b>$active</b></span>
<b>----------------------------------------------------------------------------------</b> <b>----------------------------------------------------------------------------------</b>
<b>If no tunnels are listed,</b> <b>If no tunnels are listed,</b>
<b>so they have to import their tunnel beforehand.</b>") & <b>so they have to import their tunnel beforehand.</b>")
then then
if [[ -n $active ]] if [[ -n $active ]]
then then
@ -240,13 +240,11 @@ if selection=$(yad --no-klick --list --center \
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 kill $pid
wire_g
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 kill $pid
wire_g
fi fi
fi fi