File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 22from debug import debug_print
33
44UPDATE_URL = 'https://raw.githubusercontent.com/rompelhd/AdminFreeExec/refs/heads/main/version'
5- CURRENT_VERSION = '0.2.1 '
5+ CURRENT_VERSION = '0.2.0 '
66LATEST_VERSION = None
77
88def check_update_applicationfor_update ():
@@ -24,3 +24,19 @@ def result_update():
2424
2525def update_application ():
2626 debug_print (f"Actualizando" , "INFO" )
27+
28+ URLUPD = "https://github.com/rompelhd/AdminFreeExec/releases/tag/v" + LATEST_VERSION
29+ response = requests .get (URLUPD )
30+
31+ if "AdminFreeExec.exe" in response .text :
32+ download_url = "https://github.com/rompelhd/AdminFreeExec/releases/download/v" + LATEST_VERSION + "/AdminFreeExec.exe"
33+ exe_response = requests .get (download_url )
34+
35+ if exe_response .status_code == 200 :
36+ with open ("AdminFreeExec.exe" , "wb" ) as f :
37+ f .write (exe_response .content )
38+ debug_print ("AdminFreeExec.exe descargado y sobrescrito" , "INFO" )
39+ else :
40+ debug_print ("Error al descargar AdminFreeExec.exe" , "ERROR" )
41+ else :
42+ debug_print ("AdminFreeExec.exe no encontrado" , "WARNING" )
You can’t perform that action at this time.
0 commit comments