From eee470d8ad83addb979c3bc8ce7c2daa6ed21aeb Mon Sep 17 00:00:00 2001 From: Anket Satbhai Date: Thu, 7 May 2026 18:26:30 +0530 Subject: [PATCH 1/5] ci: update tag format in release changelog internal workflows --- .github/workflows/release-changelog-internal.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/release-changelog-internal.yml b/.github/workflows/release-changelog-internal.yml index 5d96ef4c..1bdcae27 100644 --- a/.github/workflows/release-changelog-internal.yml +++ b/.github/workflows/release-changelog-internal.yml @@ -11,7 +11,7 @@ jobs: uses: ./.github/workflows/release-changelog.yml with: branch: 'master' - tag_format: X.Y.Z + tag_format: vX.Y.Z release_tag: ${{ github.ref_name }} secrets: GITHUB: ${{ secrets.GITHUB }} From 71c734988869926d38461b572fedda2008a1167a Mon Sep 17 00:00:00 2001 From: Anket Satbhai Date: Thu, 7 May 2026 23:29:55 +0530 Subject: [PATCH 2/5] ci: update tag format in release changelog workflows --- .github/workflows/release-changelog.yml | 17 +---------------- .github/workflows/release-tag.yml | 9 +++++++++ 2 files changed, 10 insertions(+), 16 deletions(-) diff --git a/.github/workflows/release-changelog.yml b/.github/workflows/release-changelog.yml index b896f3cf..3eed6b2c 100644 --- a/.github/workflows/release-changelog.yml +++ b/.github/workflows/release-changelog.yml @@ -17,14 +17,6 @@ on: required: true type: string description: "Actual release tag to validate and use" - version_type: - required: true - type: string - description: "Type of release (major/minor/patch)" - latest_tag: - required: true - type: string - description: "Previous tag for comparison" secrets: GITHUB: @@ -108,14 +100,7 @@ jobs: allowUpdates: true draft: false makeLatest: true - body: | - ${{ steps.changelog.outputs.changes }} - - **Release Type:** ${{ inputs.version_type }} - - ${{ inputs.version_type == 'major' && '⚠️ **BREAKING CHANGES:** This is a major release with breaking changes. Please review the breaking changes section in [CHANGELOG.md](https://github.com/${{ github.repository }}/blob/${{ inputs.release_tag }}/CHANGELOG.md) before upgrading.' || '' }} - - [Compare changes](https://github.com/${{ github.repository }}/compare/${{ inputs.latest_tag }}...${{ inputs.release_tag }}) + body: ${{ steps.changelog.outputs.changes }} - name: 💾 Commit CHANGELOG.md uses: stefanzweifel/git-auto-commit-action@v7 diff --git a/.github/workflows/release-tag.yml b/.github/workflows/release-tag.yml index 66ed5f7f..f64dc87b 100644 --- a/.github/workflows/release-tag.yml +++ b/.github/workflows/release-tag.yml @@ -18,6 +18,15 @@ on: type: boolean default: true description: "Whether to create changelog and release (default: true)" + version_type: + required: true + type: string + description: "Type of release (major/minor/patch)" + latest_tag: + required: true + type: string + description: "Previous tag for comparison" + secrets: GITHUB: required: true From e37fc822da526685a205ce645857fc11934b1378 Mon Sep 17 00:00:00 2001 From: Anket Satbhai Date: Fri, 8 May 2026 21:46:40 +0530 Subject: [PATCH 3/5] ci: update docs and latest tag set default false --- .github/workflows/release-tag.yml | 24 +++++++++++++++++------- docs/release-tag.md | 1 + 2 files changed, 18 insertions(+), 7 deletions(-) diff --git a/.github/workflows/release-tag.yml b/.github/workflows/release-tag.yml index f64dc87b..0ee5a16b 100644 --- a/.github/workflows/release-tag.yml +++ b/.github/workflows/release-tag.yml @@ -23,9 +23,9 @@ on: type: string description: "Type of release (major/minor/patch)" latest_tag: - required: true + required: false type: string - description: "Previous tag for comparison" + description: "Previous tag for comparison (optional - will be auto-detected if not provided)" secrets: GITHUB: @@ -76,14 +76,24 @@ jobs: echo "reason=no valid label found, skipping" >> $GITHUB_OUTPUT fi - - name: 🔖 Get latest tag (or 1.0.0 if none) + - name: 🔖 Get latest tag (or use provided latest_tag or default to 1.0.0) id: get_latest_tag if: steps.skip_tag.outputs.skip == 'false' run: | - git fetch --tags - LATEST_TAG=$(git tag --list --sort=-v:refname | head -n 1) - if [ -z "$LATEST_TAG" ]; then - LATEST_TAG="1.0.0" + # First, check if latest_tag was provided as input + if [ -n "${{ inputs.latest_tag }}" ]; then + LATEST_TAG="${{ inputs.latest_tag }}" + echo "Using provided latest_tag: $LATEST_TAG" + else + # Otherwise, fetch from git tags + git fetch --tags + LATEST_TAG=$(git tag --list --sort=-v:refname | head -n 1) + if [ -z "$LATEST_TAG" ]; then + LATEST_TAG="1.0.0" + echo "No existing tags found, defaulting to: $LATEST_TAG" + else + echo "Found latest tag from git: $LATEST_TAG" + fi fi echo "latest_tag=$LATEST_TAG" >> $GITHUB_OUTPUT diff --git a/docs/release-tag.md b/docs/release-tag.md index a31f5df0..df0b36ea 100644 --- a/docs/release-tag.md +++ b/docs/release-tag.md @@ -42,6 +42,7 @@ jobs: target_branch: ${{ github.event.pull_request.base.ref }} tag_format: "vX.Y.Z" # or "X.Y.Z" depending on your preference # create_changelog: false # 👈 Disable changelog generation + # latest_tag: ${{ github.event.inputs.base_tag }} # "" # 👈 latest_tag is optional - will be auto-detected secrets: GITHUB: ${{ secrets.TOKEN_GITHUB }} ``` \ No newline at end of file From c623d1dc1765c3c598292edc7fdd914f20cb2de0 Mon Sep 17 00:00:00 2001 From: Anket Satbhai Date: Fri, 8 May 2026 22:28:57 +0530 Subject: [PATCH 4/5] ci: remove version type from release tag workflows --- .github/workflows/release-tag.yml | 4 ---- 1 file changed, 4 deletions(-) diff --git a/.github/workflows/release-tag.yml b/.github/workflows/release-tag.yml index 0ee5a16b..9a094d64 100644 --- a/.github/workflows/release-tag.yml +++ b/.github/workflows/release-tag.yml @@ -18,10 +18,6 @@ on: type: boolean default: true description: "Whether to create changelog and release (default: true)" - version_type: - required: true - type: string - description: "Type of release (major/minor/patch)" latest_tag: required: false type: string From e78dca871ec7ba45928ab3e128309edc01420b1c Mon Sep 17 00:00:00 2001 From: Anket Satbhai Date: Fri, 8 May 2026 23:06:05 +0530 Subject: [PATCH 5/5] ci: remove version type from release tag workflows --- .github/workflows/release-tag.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/release-tag.yml b/.github/workflows/release-tag.yml index 9a094d64..b5166bfe 100644 --- a/.github/workflows/release-tag.yml +++ b/.github/workflows/release-tag.yml @@ -152,7 +152,5 @@ jobs: branch: ${{ inputs.target_branch }} tag_format: ${{ inputs.tag_format }} release_tag: ${{ needs.create-tag.outputs.final_tag }} - version_type: ${{ needs.create-tag.outputs.version_type }} - latest_tag: ${{ needs.create-tag.outputs.latest_tag }} secrets: GITHUB: ${{ secrets.GITHUB }}