Skip to content

Instantly share code, notes, and snippets.

@blachniet
Last active September 24, 2018 03:07
Show Gist options
  • Save blachniet/d527e5cb1a1a6e2eb2ab16a4d8c11a0a to your computer and use it in GitHub Desktop.
Save blachniet/d527e5cb1a1a6e2eb2ab16a4d8c11a0a to your computer and use it in GitHub Desktop.

NuGet Development Lifecycle


Version Numbers

  • NuGet Package Version
  • Assembly Version
  • Assembly File Version

NuGet Package Version


Assembly Version

  • Version number embedded in the assembly
  • Used when the CLR resolves the assembly to load
  • These versions of dependent assemblies are stored in the assembly's manifest
  • Format: major-version.minor-version.build-number.revision
  • Set with one of the following:
  • See Assembly Versioning for more details

Assembly File Version

  • Not used for resolving the assembly to load
  • Does not need to match the Assembly Version
  • Displayed on the Version tab of the Windows file properties dialog
  • Format: major-version.minor-version.build-number.revision
  • Set with one of the following:
  • See Assembly Versioning for more details

Setting Version Numbers

  • NuGet Package Version: Update according to rules set by Semantic Versioning
  • Assembly Version: Only updated for major releases
    • Major version matches NuGet Package Version's major version
    • Minor, build and revision are 0
  • Assembly File Version: Informational
    • Major, minor match Assembly Version
    • Increment the build number with every automated build
    • Set revision for "special" builds

Continuous Integration

  • TODO: CI Versioning Strategy
  • TODO: Automatic push pre-release version
  • TODO: Also build "actual" release version
  • TODO: Require manual "deploy" of actual version
  • TODO: Why we don't update Assembly Version with every build/release

Notes & References


Thank you!

Brian Lachniet

{.column}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment