$ account adamralph
MinVer is a minimalist versioning tool for .NET projects that derives version numbers from Git tags according to SemVer 2.0. It operates as both an MSBuild package (MinVer) and a standalone CLI tool (minver-cli). The core logic in MinVer.Lib walks the Git commit history from the current HEAD backward to find the latest version tag. If the current commit is tagged, that version is used as-is; otherwise, it optionally increments the version (patch by default) and appends a height (number of commits since the last tag) as pre-release identifiers. The library handles tag prefixes, custom auto-increment strategies, minimum major/minor overrides, build metadata, and height suppression. The CLI tool wraps this logic with System.CommandLine argument parsing and environment variable support, while the MSBuild package integrates directly into the .NET build pipeline, setting standard version properties (AssemblyVersion, FileVersion, PackageVersion, etc.). The repository is well-organized with a clear separation between library, CLI, and build package, and includes extensive unit and integration tests that actually create Git repositories to verify behaviour. The code demonstrates high craftsmanship with async Git operations, clean error handling, and a modular design that makes the core versioning algorithm reusable.