Bump Patch on each feature branch or commit/merge to dfevelop #3693
-
Hi guys, I want to achieve automatically bumping patch version if a feature branch or commit is merged to development but I've faced some problems. * 3c4aa7c - (31 minutes ago) Merge pull request #10 from /feat/r-22 - Vitalii (HEAD -> development, origin/development)
|\
| * dab9860 - (36 minutes ago) Sat Sep 16 15:13:54 EEST 2023 - Vitalii Dubovoy (origin/feat/r-22)
|/
* d5968a5 - (61 minutes ago) update config - Vitalii Dubovoy (tag: v1.0.4) After that, I created a new branch {
"Major": 1,
"Minor": 0,
"Patch": 5,
"PreReleaseTag": "r-66.1",
"PreReleaseTagWithDash": "-r-66.1",
"PreReleaseLabel": "r-66",
"PreReleaseLabelWithDash": "-r-66",
"PreReleaseNumber": 1,
"WeightedPreReleaseNumber": 30001,
"BuildMetaData": 3,
"BuildMetaDataPadded": "0003",
"FullBuildMetaData": "3.Branch.feat-r-66.Sha.9f5b032dd74876eb6c3c623258f2b8ff0e1f32a6",
"MajorMinorPatch": "1.0.5",
"SemVer": "1.0.5-r-66.1",
"LegacySemVer": "1.0.5-r-66-1",
"LegacySemVerPadded": "1.0.5-r-66-0001",
"AssemblySemVer": "1.0.5.0",
"AssemblySemFileVer": "1.0.5.0",
"FullSemVer": "1.0.5-r-66.1+3",
"InformationalVersion": "1.0.5-r-66.1+3.Branch.feat-r-66.Sha.9f5b032dd74876eb6c3c623258f2b8ff0e1f32a6",
"BranchName": "feat/r-66",
"EscapedBranchName": "feat-r-66",
"Sha": "9f5b032dd74876eb6c3c623258f2b8ff0e1f32a6",
"ShortSha": "9f5b032",
"NuGetVersionV2": "1.0.5-r-66-0001",
"NuGetVersion": "1.0.5-r-66-0001",
"NuGetPreReleaseTagV2": "r-66-0001",
"NuGetPreReleaseTag": "r-66-0001",
"VersionSourceSha": "d5[96](https://github.com/reply-team/main-flow/actions/runs/6207303011/job/16852415611#step:4:97)8a5468d5fcb3e9fccf3778e69e030387f09b",
"CommitsSinceVersionSource": 3,
"CommitsSinceVersionSourcePadded": "0003",
"UncommittedChanges": 0,
"CommitDate": "2023-09-16"
} After {
"Major": 1,
"Minor": 0,
"Patch": 5,
"PreReleaseTag": "alpha.4",
"PreReleaseTagWithDash": "-alpha.4",
"PreReleaseLabel": "alpha",
"PreReleaseLabelWithDash": "-alpha",
"PreReleaseNumber": 4,
"WeightedPreReleaseNumber": 4,
"BuildMetaData": null,
"BuildMetaDataPadded": "",
"FullBuildMetaData": "Branch.development.Sha.79dccc85dfc9663bb8[60](https://github.com/reply-team/main-flow/actions/runs/6207471430/job/16852713785#step:4:61)fd37bf90fe9d89e2e77e",
"MajorMinorPatch": "1.0.5",
"SemVer": "1.0.5-alpha.4",
"LegacySemVer": "1.0.5-alpha4",
"LegacySemVerPadded": "1.0.5-alpha0004",
"AssemblySemVer": "1.0.5.0",
"AssemblySemFileVer": "1.0.5.0",
"FullSemVer": "1.0.5-alpha.4",
"InformationalVersion": "1.0.5-alpha.4+Branch.development.Sha.79dccc85dfc96[63](https://github.com/reply-team/main-flow/actions/runs/6207471430/job/16852713785#step:4:64)bb860fd37bf90fe9d89e2e77e",
"BranchName": "development",
"EscapedBranchName": "development",
"Sha": "79dccc85dfc9[66](https://github.com/reply-team/main-flow/actions/runs/6207471430/job/16852713785#step:4:67)3bb860fd37bf90fe9d89e2e77e",
"ShortSha": "79dccc8",
"NuGetVersionV2": "1.0.5-alpha0004",
"NuGetVersion": "1.0.5-alpha0004",
"NuGetPreReleaseTagV2": "alpha0004",
"NuGetPreReleaseTag": "alpha0004",
"VersionSourceSha": "d59[68](https://github.com/reply-team/main-flow/actions/runs/6207471430/job/16852713785#step:4:69)a5468d5fcb3e9fccf3778e[69](https://github.com/reply-team/main-flow/actions/runs/6207471430/job/16852713785#step:4:70)e0303[87](https://github.com/reply-team/main-flow/actions/runs/6207471430/job/16852713785#step:4:88)f09b",
"CommitsSinceVersionSource": 4,
"CommitsSinceVersionSourcePadded": "0004",
"UncommittedChanges": 0,
"CommitDate": "2023-09-16"
} As I understand it should be bumped and be assembly-versioning-scheme: MajorMinorPatch
assembly-file-versioning-scheme: MajorMinorPatch
mode: ContinuousDelivery
tag-prefix: '[vV]'
continuous-delivery-fallback-tag: ci
major-version-bump-message: '\+semver:\s?(breaking|major)'
minor-version-bump-message: '\+semver:\s?(feature|minor)'
patch-version-bump-message: '\+semver:\s?(fix|patch)'
no-bump-message: '\+semver:\s?(none|skip)'
legacy-semver-padding: 4
build-metadata-padding: 4
commits-since-version-source-padding: 4
tag-pre-release-weight: 60000
commit-message-incrementing: Enabled
branches:
develop:
mode: ContinuousDeployment
tag: alpha
increment: Patch
prevent-increment-of-merged-branch-version: false
track-merge-target: true
regex: ^development?$
source-branches:
- develop
- release
tracks-release-branches: true
is-release-branch: false
is-mainline: false
pre-release-weight: 0
main:
mode: ContinuousDelivery
tag: ''
increment: Patch
prevent-increment-of-merged-branch-version: true
track-merge-target: false
regex: ^master$|^main$
source-branches: []
tracks-release-branches: false
is-release-branch: false
is-mainline: true
pre-release-weight: 55000
release:
mode: ContinuousDelivery
tag: beta
increment: None
prevent-increment-of-merged-branch-version: true
track-merge-target: false
regex: ^releases?[/-]
source-branches:
- develop
- master
- release
tracks-release-branches: false
is-release-branch: true
is-mainline: false
pre-release-weight: 30000
feature:
mode: ContinuousDelivery
tag: '{BranchName}'
increment: Inherit
regex: ^features?[/-]|^feat?[/-]
source-branches:
- develop
- master
- release
- feature
- hotfix
pre-release-weight: 30000
ignore:
sha: []
increment: Inherit
commit-date-format: yyyy-MM-dd
merge-message-formats: {}
update-build-number: true
|
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
If I understand you correct you would like to have the behavior that git version considering the merged branch based on the merge commit message right? Probably this is a new feature: [Improvement] Increment version as per source branch #3689 There are two workarounds:
|
Beta Was this translation helpful? Give feedback.
If I understand you correct you would like to have the behavior that git version considering the merged branch based on the merge commit message right?
Probably this is a new feature: [Improvement] Increment version as per source branch #3689
There are two workarounds: