Skip to content

Commit be1de4c

Browse files
authored
Speed up Github downloads by suppressing Invoke-RestMethod progress (#122)
Fixes #115
1 parent 2a3f272 commit be1de4c

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

PSDepend/PSDependScripts/GitHub.ps1

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -445,7 +445,10 @@ if(($PSDependAction -contains 'Install') -and $ShouldInstall)
445445
$OutPath = Join-Path ([System.IO.Path]::GetTempPath()) ([guid]::NewGuid().guid)
446446
New-Item -ItemType Directory -Path $OutPath -Force | Out-Null
447447
$OutFile = Join-Path $OutPath "$DependencyVersion.zip"
448+
$PreviousProgressPreference=$ProgressPreference
449+
$ProgressPreference='SilentlyContinue'
448450
Invoke-RestMethod -Uri $URL -OutFile $OutFile
451+
$ProgressPreference=$PreviousProgressPreference
449452

450453
if(-not (Test-Path $OutFile))
451454
{

0 commit comments

Comments
 (0)