Skip to content

Commit

Permalink
Merge pull request #165 from ChristophHannappel/main
Browse files Browse the repository at this point in the history
Remove unnecessary -ListAvailable which triggers a Warning in Offline Environments and wastes time.
  • Loading branch information
nyanhp authored May 2, 2024
2 parents 94fdd59 + 42e21b6 commit 425b610
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,3 +32,4 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
and a `DscWorkshop.psm1` dummy file.
- Added `TestReferenceRsop` task.
- Added `DscTagging` config data.
- Removed a `-ListAvailable` Parameter from the `Get-PackageProvider` at Resolve-Dependency.ps1 which could lead to false positives, creates a warning in offline Build Servers and slows down the process.
2 changes: 1 addition & 1 deletion Resolve-Dependency.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ Write-Progress -Activity 'Bootstrap:' -PercentComplete 0 -CurrentOperation 'NuGe
$powerShellGetModule = Import-Module -Name 'PowerShellGet' -MinimumVersion '2.0' -ErrorAction 'SilentlyContinue' -PassThru

# Install the package provider if it is not available.
$nuGetProvider = Get-PackageProvider -Name 'NuGet' -ListAvailable | Select-Object -First 1
$nuGetProvider = Get-PackageProvider -Name 'NuGet' | Select-Object -First 1

if (-not $powerShellGetModule -and -not $nuGetProvider)
{
Expand Down

0 comments on commit 425b610

Please sign in to comment.