From b1dcb290d9e662a635c4fb4c03734e7db649d5db Mon Sep 17 00:00:00 2001 From: "Jeison Yehuda Amihud (Blender Dumbass)" Date: Fri, 11 Dec 2020 17:16:55 +0000 Subject: [PATCH] Upload files to 'project_manager' --- project_manager/pm_installUpdatesLayer.py | 2 +- project_manager/pm_updateLayer.py | 11 +++++++++-- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/project_manager/pm_installUpdatesLayer.py b/project_manager/pm_installUpdatesLayer.py index 89ecde9..15f81e6 100644 --- a/project_manager/pm_installUpdatesLayer.py +++ b/project_manager/pm_installUpdatesLayer.py @@ -100,7 +100,7 @@ def layer(win): r = http.request('GET', url, preload_content=False) try: - os.mkdir(filename[:filename.rfind("/")]) + os.makedirs(filename[:filename.rfind("/")]) except: pass diff --git a/project_manager/pm_updateLayer.py b/project_manager/pm_updateLayer.py index fe4fc07..9317d28 100644 --- a/project_manager/pm_updateLayer.py +++ b/project_manager/pm_updateLayer.py @@ -14,6 +14,7 @@ import cairo # Own modules from settings import settings from settings import talk +from settings import oscalls from project_manager import pm_project #UI modules @@ -140,7 +141,13 @@ def layer(win): layer.show_text(str(version)+" "+sufix) def do(): - os.system("xdg-open "+link.replace("(", "\(").replace(")", "\)")) + + # There is a lot of problems with the BASH syntax. So if some pages + # do not load. It's probably some \ missing in some place. Click on + # the button and look in the console. Bash usually tells the error. + + oscalls.Open(link.replace("(", "\(").replace(")", "\)")\ + .replace("'", "\\'")) UI_elements.roundrect(layer, win, win.current["w"]/2-200, @@ -196,7 +203,7 @@ def layer(win): def do(): gitlink = "https://notabug.org/jyamihud/VCStudio/commits/master/" - os.system("xdg-open "+gitlink+filename) + oscalls.Open(gitlink+filename) UI_elements.roundrect(layer, win, win.current["w"]/2-220,