Skip to content

Commit

Permalink
Retry Chocolatey install to workaround failures
Browse files Browse the repository at this point in the history
Automatically retry up to 3 times on failure when installing
Chocolatey modules, using the 'appveyor-retry' script.  This can be
removed later if needed.

Sometimes Chocolatey returns a 404 for a package that exists.  This
happens a lot.  The official fix is to get the Business edition for
the more-stable private CDN, but since we're an open-source community
effort, sometimes a little kludgery goes a long way.

See http://help.appveyor.com/discussions/suggestions/816-generic-wrapper-for-retry#comment_40579488
And appveyor/ci#418
  • Loading branch information
digitalcircuit authored and javierllorente committed Jan 6, 2017
1 parent 6915115 commit 2b1567f
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion scripts/build/appveyorHelp.psm1
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,10 @@ function SETUP-QT()
function Install-ChocolatelyModule([string] $module, [string[]] $myargs)
{
Write-Host "Install chocolately package $module"
LogExec cinst $module @myargs -y
LogExec appveyor-retry cinst $module @myargs -y
# Retry installation in case it fails; remove 'appveyor-retry' to run in a generic manner
# See http://help.appveyor.com/discussions/suggestions/816-generic-wrapper-for-retry#comment_40579488
# And https://github.com/appveyor/ci/issues/418
}

function Install-CmakeGitModule([string] $url, [hashtable] $arguments)
Expand Down

0 comments on commit 2b1567f

Please sign in to comment.