Publishing pre-release (not recommended) packages from command line

Jun 1, 2011 at 2:52 PM

Is it possible to a  publish package using the nuget command line tool that is not marked as "recommended version"? This can come in handy for publishing beta build for people to try out, so something like this:
 - MyPackage.1.2 (Beta)
 - MyPackage.1.1 (Release, Recommended)
 - MyPackage.1.0 (Release)

- Pinal

Jun 1, 2011 at 3:09 PM
There have been quite a few discussions on how to do this. One train of thought is that these packages would be pushed to a different source feed where everything is an "edge" package. This is in effect scaling out, but requires more complexity than the other train of thought which is to simply add a switch to the nuspec to say it's a beta/trunk/releasecandidate/whathaveyou package. Of course then the work is all on the nuget engine and gallery to do the proper thing.
____
Rob
"Be passionate in all you do"

http://devlicio.us/blogs/rob_reynolds
http://ferventcoder.com
http://twitter.com/ferventcoder

Jun 1, 2011 at 4:18 PM

I personally like the second option more - add a new -Beta switch to push command to not make the published package the recommended version. Is that a pretty straightforward addition? I might give it try if it is.

Another thing that I think would probably come in handy is the ability to specify wildcard (*) in Package Version spec of delete command (For example, nuspec delete MyPackage 1.2.*). This way if packages, both release and beta, are published with 3 digit versions, then as part of publish step in the build process previous beta packages can be deleted easily.

- Pinal


Coordinator
Jun 1, 2011 at 4:40 PM

Here’s the spec for pre-release packages: http://nuget.codeplex.com/wikipage?title=Pre-Release%20Packages

Here’s the issue: http://nuget.codeplex.com/workitem/16

Original Discussion: http://nupack.codeplex.com/Thread/View.aspx?ThreadId=226384

We were hoping to implement it earlier, but because it requires spec changes which impact both client and server, we’re holding off for a bit. We want to batch up as many of the features that require spec changes into a single release. We’re going to be staffing up a team who can work on NuGet.org so when we do, we’ll have the capacity to do a lot of these changes that have been waiting around.

Jun 1, 2011 at 6:24 PM

This will indeed be a very nice addition! In the pre-release spec I don't see the command line tool having the ability to publish pre-release versions (like nuget push -pre) without having to add <prerelease /> element to the spec file - essentially overriding the spec file like -version does. This way build scripts can publish pre-release and release versions of a package using the same spec file without having to modify it. Is there a plan to add that functionality or did I miss it?

- Pinal