Skip to content

Commit

Permalink
Try a fix.
Browse files Browse the repository at this point in the history
  • Loading branch information
dima-iholkin committed Aug 13, 2024
1 parent 92e5187 commit fe04453
Showing 1 changed file with 11 additions and 12 deletions.
23 changes: 11 additions & 12 deletions src/Installer/_scripts/_helpers.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -145,18 +145,17 @@ function BuildInstaller {
}
# Build the installer:
Write-Output "devenv.exe started: platform $Platform, mod $Mod."
# $toLogOrNot = "/Out " + $installerDir + "\SwitchApps_Installer\Debug\log.txt"
$toLogOrNot = ""
$timeoutReached = $null
$proc = Start-Process -FilePath $devenvFile -ArgumentList ("$solutionFile /Rebuild Debug") -NoNewWindow -PassThru
$proc | Wait-Process -Timeout 60 -ErrorAction SilentlyContinue -ErrorVariable timeoutReached
if ($timeoutReached) {
# Terminate the process:
$proc | Stop-Process
# Retry the build:
Write-Output "Retrying the build..."
Start-Process -FilePath $devenvFile -ArgumentList ("$solutionFile /Rebuild Debug") -NoNewWindow -Wait
}
Start-Process -FilePath $devenvFile -ArgumentList ("$solutionFile /Rebuild Debug") -NoNewWindow -Wait
# $timeoutReached = $null
# $proc = Start-Process -FilePath $devenvFile -ArgumentList ("$solutionFile /Rebuild Debug") -NoNewWindow -PassThru
# $proc | Wait-Process -Timeout 60 -ErrorAction SilentlyContinue -ErrorVariable timeoutReached
# if ($timeoutReached) {
# # Terminate the process:
# $proc | Stop-Process
# # Retry the build:
# Write-Output "Retrying the build..."
# Start-Process -FilePath $devenvFile -ArgumentList ("$solutionFile /Rebuild Debug") -NoNewWindow -Wait
# }
Write-Output "devenv.exe finished: platform $Platform, mod $Mod."
# Revert the project file's modification after an x86 platform run:
switch ($Platform) {
Expand Down

0 comments on commit fe04453

Please sign in to comment.