Skip to content

Commit dd17571

Browse files
committed
account for prerelease version when using manifest version
1 parent 35c9f94 commit dd17571

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/code/InstallHelper.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -829,7 +829,7 @@ private Hashtable BeginPackageInstall(
829829
// However, for container registries the version must exactly match what was in the artifact manifest and then reflected in PSResourceInfo.Version.ToString()
830830
if (currentServer.Repository.ApiVersion == PSRepositoryInfo.APIVersion.ContainerRegistry)
831831
{
832-
pkgVersion = pkgToInstall.Version.ToString();
832+
pkgVersion = String.IsNullOrEmpty(pkgToInstall.Prerelease) ? pkgToInstall.Version.ToString() : $"{pkgToInstall.Version.ToString()}-{pkgToInstall.Prerelease}";
833833
}
834834

835835
// Check to see if the pkg is already installed (ie the pkg is installed and the version satisfies the version range provided via param)

0 commit comments

Comments
 (0)