Version format
Arius uses a semantic versioning scheme with the patch segment automatically set from the CI/CD run number.| Context | Format | Example |
|---|---|---|
| Production release (main branch) | 5.0.{GITHUB_RUN_NUMBER} | 5.0.123 |
| Prerelease (non-main branch) | 5.0.{GITHUB_RUN_NUMBER}-prerelease | 5.0.123-prerelease |
| Local development build | 5.0.0-local | 5.0.0-local |
Version flow
Local development
When building locally without a
GITHUB_RUN_NUMBER environment variable, MSBuild falls back to the hardcoded version 5.0.0-local. This value is embedded in the assembly at compile time.CI build
On GitHub Actions, the
GITHUB_RUN_NUMBER environment variable is automatically provided. MSBuild resolves $(GITHUB_RUN_NUMBER) during compilation, producing a version such as 5.0.123.Branch detection
A shell script in the CI pipeline inspects the branch name. For any branch other than
main, it appends the -prerelease suffix, yielding 5.0.123-prerelease.Artifact generation
All outputs — the CLI binary (
.tar.gz), the Docker image, and the GitHub Release — are tagged with the same resolved version string.Checking the current version
Run either command to print the version of your installed Arius binary:Implementation details
Project file (Arius.Cli.csproj)
The version is defined using an MSBuild conditional property:
- When
GITHUB_RUN_NUMBERis set (i.e., running in GitHub Actions), the version resolves to5.0.$(GITHUB_RUN_NUMBER). - Otherwise it falls back to
5.0.0-local.
Runtime retrieval (Program.cs)
The GetVersion() method reads AssemblyFileVersionAttribute from the compiled assembly at runtime. This is the value displayed to users in the CLI output.
Updating the major or minor version
To increment the major or minor segment (e.g., from5.0 to 6.0), update both conditional <Version> elements in src/Arius.Cli/Arius.Cli.csproj:
- Keep the
$(GITHUB_RUN_NUMBER)placeholder for CI builds. - Keep the
-localsuffix for the local development fallback.