verbesserungen

This commit is contained in:
Désiré Werner Menrath 2023-10-28 22:45:53 +02:00
parent 3f1330f850
commit d0fb85ab4e
3 changed files with 8 additions and 6 deletions

View File

@ -9,7 +9,7 @@ a_user=$(whoami)
mkdir -p /home/"$a_user"/.icons ; cp icons/* /home/"$a_user"/.icons/ ; mkdir -p /home/"$a_user"/.config/wg_nmcli
wait;
echo "Icons erfolgreich installiert"
echo Icons erfolgreich installiert
wait;
# abfrage ob yad installiert ist, wenn nicht dann installiere automatisch yad. Nur Debian basierende Systeme!
@ -49,6 +49,7 @@ sudo cp wire_g wg_stop /sbin/ ; sudo chmod +x /sbin/wire_g ; sudo chmod +x /sbin
wait; sudo cp Wire-G.desktop /usr/share/applications/
echo
echo "Installation erfolgreich!"
echo
read -n 1 -s -r -p "Zum Fenster schließen eine Taste drücken"
clear

View File

@ -1,7 +1,7 @@
#!/bin/bash
a_user=$(whoami)
cd
cd || exit
rm -f /home/$a_user/.icons/wireguard-active.png wireguard-stop.png wireguard-vpn.png wg-import.png wg-trash.png wg-info.png
wait;
rm -r /home/$a_user/.config/wg_nmcli
@ -13,6 +13,7 @@ wait;
sudo rm /usr/share/applications/Wire-G.desktop
echo
echo "deinstallation erfolgreich!"
echo
read -n 1 -s -r -p "Zum Fenster schließen eine Taste drücken"
clear

8
wire_g
View File

@ -84,7 +84,7 @@ remove(){
active=$(cat ${wg_wdir}.wg_noactive.txt)
selection=$(yad --no-click --list --height=300 --width=60 \
--title="Wire-G Trash" \
--title="Wire-G Trash" --center \
--fixed --buttons-layout=center \
--button="OK" --button="Abbrechen" \
--separator="" --window-icon=${wg_pic}wg-trash.png \
@ -92,7 +92,7 @@ remove(){
if [ "$?" = "0" ]
then
nmcli connection delete $selection &> ${wg_wdir}.tmp.txt
erfolg=$(grep -i "Verbindung erfolgreich gelöscht" ${wg_wdir}.tmp.txt)
success=$(grep -i "erfolgreich gelöscht" ${wg_wdir}.tmp.txt)
if [ "$?" = "0" ]
then
yad --window-icon=${wg_pic}wg-trash.png \
@ -122,7 +122,7 @@ export -f remove
connect(){
erfolg=$(grep -i "Verbindung wurde erfolgreich aktiviert" ${wg_wdir}.tmp.txt)
success=$(grep -i "erfolgreich aktiviert" ${wg_wdir}.tmp.txt)
if [ "$?" = "0" ]
then
nmcli con mod $selection connection.autoconnect no
@ -135,7 +135,7 @@ connect(){
# hiermit wird die Farbe für Variable $active festgelegt mit fetter Schrift.
selection=$(yad --no-click --list \
--close-on-unfocus --tab=Löschen \
--close-on-unfocus --center \
--height=300 --width=60 --title="Wire-G" \
--fixed --buttons-layout=center \
--button="OK" --button="Abbrechen" \