Reputation:
I have a package that contains the CPython installer and attempts to install it for the client.
In the event that there is a corrupt install, the %ERRORLEVEL%
variable gets set to 1603. From the docs I can issue a command to uninstall, but it will fail in the installed instance requires a repair (such as the user deleted the directory before trying to uninstall). To resolve I'd like to attempt a repair using the installer in this case, but the docs do not list a way to do this via the command line.
I believe the installer is an MSI labeled as an EXE as the source uses WiX. I'm not intimately familiar with MSI or WiX, but I'd think there is some way to access the "Repair" feature available from double clicking the installer via the command line.
Is there a way to accomplish this?
Upvotes: 3
Views: 5160
Reputation: 21
Using Powershell, do this:
Invoke-Expression "& 'D:\python-3.9.5-amd64.exe' /repair /passive"
Upvotes: 2