2e00b8df83
Releases are X.Y.Z from git tags vX.Y.Z; builds between releases are X.Y.Z.N, N commits after the last release (git describe, 1-3 digit majors only, so the calendar-era tags never count); with no release tag reachable a build is 0.0.0.<commits>. Every version is 3-4 numeric fields, refused when it does not fit an MSI ProductVersion or has a calendar-era major. scripts/Get-Version.ps1 computes it (Get-UnifiedVersion.ps1 stays as the old entry point). scripts/Get-NextRelease.ps1 runs semantic-release in dry-run mode (pinned in build/release, conventionalcommits preset, main only) for the version a release publishes, or for nothing when the commits since the last release call for none. Directory.Build.props stamps four-field assembly/file versions and InformationalVersion X.Y.Z[.N]+<short commit>; a build not handed a version reads it from git (build/Version.targets), otherwise 0.0.0.0. BREAKING CHANGE: versions are no longer yyyy.MM.dd.HHmm. The first release after the seed tag v0.1.0 is 1.0.0, which every comparison orders after every calendar-era version. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
14 lines
371 B
PowerShell
14 lines
371 B
PowerShell
<#
|
|
.SYNOPSIS
|
|
Kept for callers of the old name: the build version from scripts/Get-Version.ps1
|
|
(X.Y.Z for a release, X.Y.Z.N for a build N commits after it). Honors -Version
|
|
and UNIFIED_VERSION the same way.
|
|
#>
|
|
[CmdletBinding()]
|
|
param(
|
|
[string]$Version
|
|
)
|
|
|
|
$ErrorActionPreference = 'Stop'
|
|
& (Join-Path $PSScriptRoot 'Get-Version.ps1') -Version $Version -Format Version
|