Search code examples
tfsnugetazure-artifacts

NuGet package only showing up as prerelease in TFS-managed feed


I'm using TFS 2017 to build and publish a NuGet package to an internal feed managed by TFS. Pushing to the feed succeeds, however the package is only listed as "prerelease" and not as stable although I promoted the package to a release view. How do I need to configure TFS to make the package show up as stable?


Solution

  • Turns out that NuGet uses Semantic Versioning to determine if a package is stable or in prerelease. In my case I used automatic build version as configured in the build activity which resulted in a version number like 1.0.0-ci-20180507-070157. Since that string includes a SemVer prerelease identifier (-ci-.....), the package is not published as stable. I changed the version to one without prerelease indentifier (e.g. 1.0.0.1234) and the package shows up as stable.