13 Commits

Author SHA1 Message Date
8754e7ecda Merge pull request '- Update Translate Files' (#28) from 1.11.1824 into main
Reviewed-on: #28
2024-11-17 11:48:24 +01:00
a6742a0c0e - Update Translate Files 2024-11-17 11:46:11 +01:00
6b75713121 Merge pull request '1.11.1824' (#27) from 1.11.1824 into main
Reviewed-on: #27
2024-11-17 11:45:10 +01:00
762694aa94 - Update Translate Files 2024-11-17 11:42:58 +01:00
cc54f329fe - Update Translate Files 2024-11-17 11:41:13 +01:00
8c01c1b984 - Update Translate Files 2024-11-17 11:40:33 +01:00
ebafdbdcb3 - - Fix Checkbutton Autostart when first install Wire-Py 2024-11-17 10:48:47 +01:00
ce4f6c84dc - - Fix Checkbutton Autostart when first install Wire-Py 2024-11-15 18:09:21 +01:00
b68908eaef Merge pull request '1.11.1124' (#25) from 1.11.1124 into main
Reviewed-on: #25
2024-11-13 17:51:07 +01:00
c4565ed169 - fix return 'no Updates' 2024-11-10 20:57:52 +01:00
485cfff457 - fix return 'no Updates' 2024-11-10 20:57:19 +01:00
1a0fc74a80 - fix return 'no Updates' 2024-11-10 20:55:33 +01:00
971c86c97f - Translate file de_De complete
- new FrameWidget for rename Entry and rename Button
2024-11-10 20:31:27 +01:00
5 changed files with 16 additions and 15 deletions

View File

@ -17,6 +17,12 @@ My standard System: Linux Mint 22 Cinnamon
### Added ### Added
10-11-2024 10-11-2024
- Fix Checkbutton Autostart when first install Wire-Py
- Update Translate Files
### Added
10-11-2024
- Translate file de_De complete - Translate file de_De complete
- new FrameWidget for rename Entry and rename Button - new FrameWidget for rename Entry and rename Button

View File

@ -32,7 +32,6 @@ class GiteaUpdate:
the taskbar image for the “Download OK” window, the taskbar image for the the taskbar image for the “Download OK” window, the taskbar image for the
“Download error” window and the variable res “Download error” window and the variable res
""" """
@staticmethod @staticmethod
def api_down(update_api_url, version): def api_down(update_api_url, version):
try: try:
@ -45,7 +44,7 @@ class GiteaUpdate:
if version[3:] != response_dict['tag_name']: if version[3:] != response_dict['tag_name']:
return response_dict['tag_name'] return response_dict['tag_name']
else: else:
return _('No Updates') return 'No Updates'
else: else:
return 'False' return 'False'
except requests.exceptions.ConnectionError: except requests.exceptions.ConnectionError:
@ -93,7 +92,6 @@ def msg_window(img_w, img_i, w_title, w_txt, txt2=None, com=None):
txt2 = Text for Button two txt2 = Text for Button two
com = function for Button command com = function for Button command
""" """
msg = tk.Toplevel() msg = tk.Toplevel()
msg.resizable(width=False, height=False) msg.resizable(width=False, height=False)
msg.title(w_title) msg.title(w_title)
@ -135,7 +133,6 @@ class Tunnel:
The config file is packed into a dictionary, The config file is packed into a dictionary,
to display the values Address , DNS and Peer in the labels to display the values Address , DNS and Peer in the labels
""" """
@classmethod @classmethod
def con_to_dict(cls, file): def con_to_dict(cls, file):
@ -180,7 +177,6 @@ class Tunnel:
""" """
Shows the Active Tunnel Shows the Active Tunnel
""" """
@staticmethod @staticmethod
def active(): def active():
@ -195,7 +191,6 @@ class Tunnel:
""" """
Shows all existing Wireguard tunnels Shows all existing Wireguard tunnels
""" """
@staticmethod @staticmethod
def list(): def list():
wg_s = os.popen('nmcli con show | grep -iPo "(.*)(wireguard)"').read().split() wg_s = os.popen('nmcli con show | grep -iPo "(.*)(wireguard)"').read().split()
@ -209,7 +204,6 @@ class Tunnel:
A zipfile with current date and time is created A zipfile with current date and time is created
in the user's home directory with correct right in the user's home directory with correct right
""" """
@staticmethod @staticmethod
def export(): def export():
_u1 = str(_u[6:]) _u1 = str(_u[6:])

Binary file not shown.

Binary file not shown.

View File

@ -14,7 +14,7 @@ from cls_mth_fc import (Tunnel, msg_window, GiteaUpdate, _u, wg_tips, wg_set)
tcl_path = Path('/usr/share/TK-Themes') tcl_path = Path('/usr/share/TK-Themes')
''' 1 = 1. Year, 09 = Month of the Year, 2924 = Day and Year of the Year ''' ''' 1 = 1. Year, 09 = Month of the Year, 2924 = Day and Year of the Year '''
version = 'v. 1.11.1024' version = 'v. 1.11.1824'
res = GiteaUpdate.api_down('https://git.ilunix.de/api/v1/repos/punix/Wire-Py/releases', version) res = GiteaUpdate.api_down('https://git.ilunix.de/api/v1/repos/punix/Wire-Py/releases', version)
@ -427,8 +427,8 @@ class FrameWidgets(ttk.Frame):
self.l_box.delete(self.select_tunnel[0]) self.l_box.delete(self.select_tunnel[0])
with open(wg_set, 'r') as set_file6: with open(wg_set, 'r') as set_file6:
lines6 = set_file6.readlines() lines6 = set_file6.readlines()
if select_tl == lines6[7].strip() and 'off' not in lines6[7].strip(): if select_tl == lines6[7].strip() and 'off\n' not in lines6[7].strip():
lines6[7] = 'off' lines6[7] = 'off\n'
with open(wg_set, 'w') as set_file7: with open(wg_set, 'w') as set_file7:
set_file7.writelines(lines6) set_file7.writelines(lines6)
self.selected_option.set(0) self.selected_option.set(0)
@ -649,7 +649,7 @@ class FrameWidgets(ttk.Frame):
self.StrVar.set(value=self.a) self.StrVar.set(value=self.a)
with open(wg_set, 'r') as set_file5: with open(wg_set, 'r') as set_file5:
lines5 = set_file5.readlines() lines5 = set_file5.readlines()
if select_tl == lines5[7].strip() and 'off' not in lines5[7].strip(): if select_tl == lines5[7].strip() and 'off\n' not in lines5[7].strip():
lines5[7] = new_a_connect lines5[7] = new_a_connect
with open(wg_set, 'w') as theme_set5: with open(wg_set, 'w') as theme_set5:
theme_set5.writelines(lines5) theme_set5.writelines(lines5)
@ -906,7 +906,7 @@ class FrameWidgets(ttk.Frame):
if self.selected_option.get() == 0: if self.selected_option.get() == 0:
with open(wg_set, 'r') as set_file3: with open(wg_set, 'r') as set_file3:
lines3 = set_file3.readlines() lines3 = set_file3.readlines()
lines3[7] = 'off' lines3[7] = 'off\n'
with open(wg_set, 'w') as set_file3: with open(wg_set, 'w') as set_file3:
set_file3.writelines(lines3) set_file3.writelines(lines3)
@ -936,15 +936,16 @@ class FrameWidgets(ttk.Frame):
with open(wg_set, 'r') as set_file4: with open(wg_set, 'r') as set_file4:
lines4 = set_file4.readlines() lines4 = set_file4.readlines()
if lines4[7] != 'off': if lines4[7] != 'off\n':
print(lines4[7])
self.selected_option.set(1) self.selected_option.set(1)
self.autoconnect_var.set('') self.autoconnect_var.set('')
self.auto_con = lines4[7] self.auto_con = lines4[7]
else: else:
self.selected_option.set(0)
self.wg_autostart.configure(state='disabled')
self.auto_con = _('no Autoconnect') self.auto_con = _('no Autoconnect')
self.autoconnect_var.set('') self.autoconnect_var.set('')
self.autoconnect_var = tk.StringVar() self.autoconnect_var = tk.StringVar()
self.autoconnect_var.set(self.auto_con) self.autoconnect_var.set(self.auto_con)