You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
if ($version.IsPreRelease-or$version.HasMetadata) {
271
-
Write-Warning'A specification with a prerelease version was detected, forcing -Prerelease switch. Specify -Prerelease in the future to avoid this warning.'
272
-
$Prerelease=$true
273
-
break
274
-
}
275
-
}
276
-
277
269
# A deduplicated list of modules to install
278
270
[HashSet[ModuleFastInfo]]$modulesToInstall=@{}
279
271
@@ -363,7 +355,10 @@ function Get-ModuleFastPlan {
if (($candidate.IsPrerelease-or$candidate.HasMetadata) -and-not$Prerelease) { continue }
358
+
if (($candidate.IsPrerelease-or$candidate.HasMetadata) -and-not ($currentModuleSpec.PreRelease-or$Prerelease)) {
359
+
Write-Debug"Skipping candidate $candidate because it is a prerelease and prerelease was not specified either with the -Prerelease parameter or with a ! on the module name."
360
+
continue
361
+
}
367
362
368
363
if ($currentModuleSpec.SatisfiedBy($candidate)) {
369
364
Write-Debug"$currentModuleSpec`: Found satisfying version $candidate in the inlined index."
@@ -707,16 +702,22 @@ class ModuleFastInfo: IComparable {
0 commit comments