Cool Stuff

This commit is contained in:
UnlimitedCookies
2021-08-22 23:12:38 +02:00
parent ec0bd91195
commit a585fef02e
8 changed files with 242 additions and 36 deletions

31
remove.ins Normal file
View File

@@ -0,0 +1,31 @@
[Initial]
Message=Deinstalliere Python...
DefVar $ExitCode$
DefVar $Version$
[Aktionen]
ShowBitmap "%ScriptPath%\logo.png" "MDG Python"
Sub_PrepareSetup
WinBatch_Setup
Files_Cleanup
[Sub_PrepareSetup]
Set $Version$ = GetValue("productversion", GetProductMap)
[WinBatch_Setup]
"%ScriptPath%\data\python-$Version$-amd64.exe" /quiet /uninstall
[Files_Cleanup]
delete -sf "%ProgramFiles64Dir%\Python39\"
[Sub_HandleExitCode]
; check return code
Set $ExitCode$ = GetLastExitCode
comment "GetLastExitCode: " + $ExitCode$
if not($ExitCode$ = "0" or $ExitCode$ = "1605" or $ExitCode$ = "3010")
; 0 ERROR_SUCCESS
; 1605 ERROR_UNKNOWN_PRODUCT
; 3010 ERROR_SUCCESS_REBOOT_REQUIRED
LogError "Fatal: setup returned exit code " + $ExitCode$
IsFatalError
endif