I have a special case: we are moving our legacy app to totally new architecture.
The legacy app is tagged WITHOUT the v prefix, based ONLY on the SemVer notation. For example, latest tag is: 0.0.91
The new app is tagged WITH the v prefix. For example, latest tag is: v1.0.0
I have upgrade my GitHub Action CI/CD to continue to support the both notation, relay on this, I can easily identify old and new tags/packages. In the futur, it will be easy to remove all old stuff without to check if current tag is old or new app.
Both stacks could have new version.
Context: currents tags on my git hub repo:
Actual behavior
If I push something related to my old stack, I'm attending that the new tag will be 0.0.92. With the version 6.0, it was not the case, the latest tag used was v1.0.0 (related to the new stack), so, new tag will be 1.0.1
Attended & new behavior
I use the new option prefix_match_tag I introduce to informe the github-tag-action I want that all tags must MATCH with tag_prefix to be valide. Below, usage example:
- name: Bump version and push tag
uses: gmocquet/github-tag-action@v6.1.0
with:
github_token: ${{ secrets.BOT_PAT }}
tag_prefix: ""
release_branches: "main-v1"
create_annotated_tag: true
dry_run: true
prefix_match_tag: true
Now, when I push something related to old stack, all tags prefixed by v are exclude, so, I have the attended behavior: new version is 0.0.92
I have a special case: we are moving our legacy app to totally new architecture.
The legacy app is tagged WITHOUT the
v
prefix, based ONLY on theSemVer
notation. For example, latest tag is:0.0.91
The new app is tagged WITH thev
prefix. For example, latest tag is:v1.0.0
I have upgrade my GitHub Action CI/CD to continue to support the both notation, relay on this, I can easily identify
old
andnew
tags/packages. In the futur, it will be easy to remove all old stuff without to check if current tag isold
ornew
app.Both stacks could have new version.
Context: currents tags on my git hub repo:
Actual behavior
If I push something related to my old stack, I'm attending that the new tag will be
0.0.92
. With the version6.0
, it was not the case, the latest tag used wasv1.0.0
(related to the new stack), so, new tag will be1.0.1
Attended & new behavior
I use the new option
prefix_match_tag
I introduce to informe thegithub-tag-action
I want that all tags mustMATCH
withtag_prefix
to be valide. Below, usage example:Now, when I push something related to old stack, all tags prefixed by
v
are exclude, so, I have the attended behavior: new version is0.0.92