diff --git a/README.md b/README.md index 4f4f7bc..4340455 100644 --- a/README.md +++ b/README.md @@ -11,7 +11,7 @@ This repo includes support for versioning numbers. This support includes: build numbering. It is NOT a CSemVer but IS a SemVer. ## Status -![NuGet](https://img.shields.io/nuget/dt/Ubiquity.NET.Versioning.svg) +[![NuGet Version](https://img.shields.io/nuget/v/Ubiquity.NET.Versioning)](https://www.nuget.org/packages/Ubiquity.NET.Versioning)![NuGet](https://img.shields.io/nuget/dt/Ubiquity.NET.Versioning.svg) ![PR/CI Work Flow Status](https://img.shields.io/github/actions/workflow/status/UbiquityDotNET/Ubiquity.NET.Versioning/pr-build.yml?label=PR%2FCI%20Build%20Status) ![Release Work Flow Status](https://img.shields.io/github/actions/workflow/status/UbiquityDotNET/Ubiquity.NET.Versioning/release-build.yml?label=Release%20Build%20Status) @@ -62,4 +62,4 @@ Documentation on building and general maintenance of this repo are provided in t ---- 1See: [This issue](https://github.com/CK-Build/csemver.org/issues/2) which was reported upon -testing this library and found inconsistencies. +testing this library and found ambiguities. diff --git a/docfx/versioning-lib/index.md b/docfx/versioning-lib/index.md index fa16289..7eb16e0 100644 --- a/docfx/versioning-lib/index.md +++ b/docfx/versioning-lib/index.md @@ -3,10 +3,13 @@ The Ubiquity.NET.Versioning library provides types to support use of versioning 1) [Semantic Versioning](https://semver.org) 2) [Constrained Semantic Versioning](https://csemver.org) - Including Continuous Integration (CI) via CSemVer-CI + - Including FileVersion QUAD representation + - Including OrderedVersion integral representation. It is viable as a standalone package to allow validation of or comparisons to versions reported at runtime. (Especially from native interop that does not support package -dependencies or versioning at runtime.) +dependencies or versioning at runtime.) The [Ubiquity.NET.Versioning.Build.Tasks](https://www.nuget.org/packages/Ubiquity.NET.Versioning.Build.Tasks) +is a companion project that implements automated build support for CSemVer. ## Example ``` C# diff --git a/src/Ubiquity.NET.Versioning.UT/ParsedBuildVersionXmlTests.cs b/src/Ubiquity.NET.Versioning.UT/ParsedBuildVersionXmlTests.cs index 532defb..0d4c5bd 100644 --- a/src/Ubiquity.NET.Versioning.UT/ParsedBuildVersionXmlTests.cs +++ b/src/Ubiquity.NET.Versioning.UT/ParsedBuildVersionXmlTests.cs @@ -5,6 +5,7 @@ // ----------------------------------------------------------------------- using System; +using System.Diagnostics.CodeAnalysis; using System.IO; using System.Xml.Linq; @@ -83,6 +84,7 @@ private static readonly XDocument InvalidAttributeXml ) ); + [SuppressMessage( "StyleCop.CSharp.NamingRules", "SA1310:Field names should not contain underscore", Justification = "Underscores substitute for otherwise invalid delimiter" )] private static readonly XDocument Xml_5_0_4 = new( new XElement("BuildVersionData", new XAttribute("BuildMajor", "5"), diff --git a/src/Ubiquity.NET.Versioning.UT/ValidationWithTask.cs b/src/Ubiquity.NET.Versioning.UT/ValidationWithTask.cs index c2f1707..f68f568 100644 --- a/src/Ubiquity.NET.Versioning.UT/ValidationWithTask.cs +++ b/src/Ubiquity.NET.Versioning.UT/ValidationWithTask.cs @@ -40,7 +40,7 @@ public void ValidateRepoAssemblyVersion( ) // NOTE: Concept of a CI build used here (and in CSemVer[-CI]) is anything that is NOT // a release build. It does not distinguish between local, PR, or "nightly" etc... // That information is lost in creation of the FileVersionQuad form anyway and - // only a single bit represents a CSemVer or CSemVer-CI. + // only a single bit represents a CI build. BuildKind buildKind = GetBuildKind(); bool isCIBuild = buildKind != BuildKind.ReleaseBuild; @@ -88,8 +88,9 @@ public void ValidateRepoAssemblyVersion( ) // This is where the Patch+1 behavior is validated against the task // Both this library and the generated version for this library (from the task) // should agree on the build and base build. Bug: https://github.com/UbiquityDotNET/CSemVer.GitBuild/issues/64 - // on the task deals with the incorrect assumption that baseBuild == build and - // generally ignores the Patch+1 requirement. + // on the task dealt with the previously incorrect assumption that baseBuild == build and + // generally ignored the Patch+1 requirement. That has since been fixed but worth keeping in mind + // as this point has caused a great deal of confusion. Assert.AreEqual( expectedVersion.Major, actualCI.Major ); Assert.AreEqual( expectedVersion.Minor, actualCI.Minor ); Assert.AreEqual( expectedVersion.Patch, actualCI.Patch );