RamblingCookieMonster / PSDepend

PowerShell Dependency Handler
MIT License
282 stars 75 forks source link

Invoke-WebRequest and Invoke-RestMethod are slow because of the progress bar #115

Open mpiederiet opened 4 years ago

mpiederiet commented 4 years ago

Some of the dependency scripts (in particular PSDependScripts\Github.ps1) use Invoke-WebRequest and Invoke-Restmethod to download files. As described on multiple sites, this is very slow because of the shown progress bar: https://github.com/PowerShell/PowerShell/issues/2238.

Proposed solution: (PSDepend\Github.ps1, Line 448, replace with following lines): $PreviousProgressPreference=$ProgressPreference $ProgressPreference='SilentlyContinue' Invoke-RestMethod -Uri $URL -OutFile $OutFile $ProgressPreference=$PreviousProgressPreference