[Updated] D12560: contrib: add a hint if the Windows dependency MSI is already installed

mharbison72 (Matt Harbison) phabricator at mercurial-scm.org
Tue Apr 19 09:19:39 UTC 2022


Closed by commit rHG246ee748fe67: contrib: add a hint if the Windows dependency MSI is already installed (authored by mharbison72).
This revision was automatically updated to reflect the committed changes.

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D12560?vs=33181&id=33215

CHANGES SINCE LAST ACTION
  https://phab.mercurial-scm.org/D12560/new/

REVISION DETAIL
  https://phab.mercurial-scm.org/D12560

AFFECTED FILES
  contrib/install-windows-dependencies.ps1

CHANGE DETAILS

diff --git a/contrib/install-windows-dependencies.ps1 b/contrib/install-windows-dependencies.ps1
--- a/contrib/install-windows-dependencies.ps1
+++ b/contrib/install-windows-dependencies.ps1
@@ -90,7 +90,13 @@
     $p = Start-Process -FilePath $path -ArgumentList $arguments -Wait -PassThru -WindowStyle Hidden
 
     if ($p.ExitCode -ne 0) {
-        throw "process exited non-0: $($p.ExitCode)"
+        # If the MSI is already installed, ignore the error
+        if ($p.ExitCode -eq 1638) {
+            Write-Output "program already installed; continuing..."
+        }
+        else {
+            throw "process exited non-0: $($p.ExitCode)"
+        }
     }
 }
 
@@ -150,7 +156,7 @@
     Install-Python3 "Python 3.7 32-bit" ${prefix}\assets\python37-x86.exe ${prefix}\python37-x86 ${pip}
     Install-Python3 "Python 3.7 64-bit" ${prefix}\assets\python37-x64.exe ${prefix}\python37-x64 ${pip}
     Install-Python3 "Python 3.8 32-bit" ${prefix}\assets\python38-x86.exe ${prefix}\python38-x86 ${pip}
-#    Install-Python3 "Python 3.8 64-bit" ${prefix}\assets\python38-x64.exe ${prefix}\python38-x64 ${pip}
+    Install-Python3 "Python 3.8 64-bit" ${prefix}\assets\python38-x64.exe ${prefix}\python38-x64 ${pip}
     Install-Python3 "Python 3.9 32-bit" ${prefix}\assets\python39-x86.exe ${prefix}\python39-x86 ${pip}
     Install-Python3 "Python 3.9 64-bit" ${prefix}\assets\python39-x64.exe ${prefix}\python39-x64 ${pip}
     Install-Python3 "Python 3.10 32-bit" ${prefix}\assets\python310-x86.exe ${prefix}\python310-x86 ${pip}



To: mharbison72, #hg-reviewers, Alphare
Cc: mercurial-patches
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mercurial-scm.org/pipermail/mercurial-patches/attachments/20220419/1607d278/attachment-0002.html>


More information about the Mercurial-patches mailing list