我一生都无法弄清楚如何将PreReleaseLabel
Alpha 或 GitVersionConfig.yaml 中的任何内容更改为 Alpha。有没有办法让 gitversion 追踪它的想法?
这是我的 gitversion 输出:
GitVersion.exe
{
"Major":3,
"Minor":10,
"Patch":1,
"PreReleaseTag":"unstable.1",
"PreReleaseTagWithDash":"-unstable.1",
"PreReleaseLabel":"unstable",
"PreReleaseNumber":1,
"BuildMetaData":"",
"BuildMetaDataPadded":"",
"FullBuildMetaData":"Branch.develop.Sha.93033f2b5a166cb44da9dff6d72697de68096499",
"MajorMinorPatch":"3.10.1",
"SemVer":"3.10.1-unstable.1",
"LegacySemVer":"3.10.1-unstable1",
"LegacySemVerPadded":"3.10.1-unstable0001",
"AssemblySemVer":"3.10.1.0",
"FullSemVer":"3.10.1-unstable.1",
"InformationalVersion":"3.10.1-unstable.1+Branch.develop.Sha.93033f2b5a166cb44da9dff6d72697de68096499",
"BranchName":"develop",
"Sha":"93033f2b5a166cb44da9dff6d72697de68096499",
"NuGetVersionV2":"3.10.1-unstable0001",
"NuGetVersion":"3.10.1-unstable0001",
"CommitsSinceVersionSource":1,
"CommitsSinceVersionSourcePadded":"0001",
"CommitDate":"2016-02-10"
}
或者
GitVersion.exe /输出构建服务器
INFO [02/10/16 17:00:35:73] Working directory: C:\BuildAgents\Agent-XXX\_work\1\s
INFO [02/10/16 17:00:35:78] Project root is: C:\BuildAgents\Agent-XXX\_work\1\s
INFO [02/10/16 17:00:35:93] Using latest commit on specified branch
INFO [02/10/16 17:00:35:96] Running against branch: develop (93033f2b5a166cb44da9dff6d72697de68096499)
INFO [02/10/16 17:00:35:98] Begin: Calculating base versions
INFO [02/10/16 17:00:36:14] Fallback base version: 0.1.0 with commit count source 5c313e354c091a41573564037215c3cfc5e43b80
INFO [02/10/16 17:00:36:29] NextVersion in GitVersionConfig.yaml: 3.10.0 with commit count source External Source
INFO [02/10/16 17:00:36:53] Git tag 'v3.10.0': 3.10.0 with commit count source cedfccd47c77bca9ea4ccd43aa7492afc169a493
INFO [02/10/16 17:00:36:59] Git tag 'v3.10.0': 3.10.0 with commit count source cedfccd47c77bca9ea4ccd43aa7492afc169a493
INFO [02/10/16 17:00:36:84] Found multiple base versions which will produce the same SemVer (3.10.1), taking oldest source for commit counting (Git tag 'v3.10.0')
INFO [02/10/16 17:00:36:84] Base version used: Git tag 'v3.10.0': 3.10.0 with commit count source cedfccd47c77bca9ea4ccd43aa7492afc169a493
INFO [02/10/16 17:00:36:84] End: Calculating base versions (Took: 859.31ms)
INFO [02/10/16 17:00:36:96] 1 commits found between cedfccd47c77bca9ea4ccd43aa7492afc169a493 and 93033f2b5a166cb44da9dff6d72697de68096499
这是我的 GitVersionConfig.yaml 文件
next-version: 3.10.0
mode: ContinuousDeployment
continuous-delivery-fallback-tag: Alpha
branches:
develop:
mode: ContinuousDeployment
tag:
increment: Patch
prevent-increment-of-merged-branch-version: true
track-merge-target: false
features?[/-]:
mode: ContinuousDeployment
tag: useBranchName
increment: Minor
prevent-increment-of-merged-branch-version: false
track-merge-target: false