Skip to main content

Nuget Package Versioning using GIT Versions

Git Version is a library which helps to manage the versions of packages.

How To Manage Nugget Version.​

There are various ways to manage versions depending on your CI/CD Pipeline. But here for **CM Connect **we will be using tags for generating nuget package.

It is necessary to create tag for publishing nuget package

Nuget packages can be publish into two ways.

  • Release
  • Pre-Release

Release Version​

For creating a release version of nuget package follow the steps:

  1. Open the GitLab Repo
  2. From Left Menu Repository > Tags
  3. Click on New Tag
  4. Tag Name must be in the format v1.0.0 or should follow /^v[0-9]+\.[0-9]+\.[0-9]+$/ regex pattern
  5. Select the Branch as Main.
  6. Create Tag

**Warning: Branch should be Main Branch **and tag name must follow the pattern /^v[0-9]+\.[0-9]+\.[0-9]+$/

Pre-Release Version​

For creating a pre-release version of nuget package follow the steps:

  1. Open the GitLab Repo
  2. From Left Menu Repository > Tags
  3. Click on New Tag
  4. Tag Name must be in the format v1.0.0-alpha / v1.0.0-beta / v1.0.0-alpha1 etc or should follow /^v[0-9]+\.[0-9]+\.[0-9]+\-.*/ regex pattern
  5. Select any Branch.
  6. Create Tag

Warning: TTag name must follow the patten /^v[0-9]+\.[0-9]+\.[0-9]+\-.*/