Project.json version format

I am looking for a formal definition of version number formats for .NET Core project.json files.

version
Visual studio creates the default version number "1.0.0- *". I would like this to mean that * is updated on successive builds (this is not the case). The build version number is 1.0.0. What does * mean and what are the legal options?

dependencies
I was expecting dependency numbering to follow nuget rules given that KPM is basically a nuget interface, but it doesn't seem to support parenthesis numbering (like "[1,2)") - I get an "invalid version string", when I try to use anything other than an empty or xx- * format.

Outside of the source, does anyone have a link to a formal definition?

+5
source share
1 answer

I am not sure what is wrong with finding the source to determine. I think the most accurate place to search, especially now that vNext is hosted on GitHub.

Considering the described exception, we point to SemanticVersion.cs.

In the TryParseInternal method, TryParseInternal pretty obvious why you ran into problems when trying to declare min / max versions this way. This method simply does not use processing [,] or (,) .

If we look at the standard specification of the NuGet version, it is obvious that TryParseVersionSpec has built-in processing.

As for the documentation specifying the valid formats, you may have to wait until it leaves the CTP state. If you think this is a problem, you should document it on GitHub . The authors are very sensitive to these issues. Personally, I'm not sure if there is a need to install the maximum version of the dependency when deploying it with your assembly.

0
source

Source: https://habr.com/ru/post/1207477/


All Articles