diff --git a/.github/workflows/main-tag.yml b/.github/workflows/main-tag.yml index 5cb5d28..b1139a7 100644 --- a/.github/workflows/main-tag.yml +++ b/.github/workflows/main-tag.yml @@ -37,9 +37,4 @@ jobs: with: branch: main commit_message: "docs: update CHANGELOG.md for ${{ github.ref_name }} [skip ci]" - file_pattern: CHANGELOG.md - - - name: Update major tag to ${{ github.ref_name }} - uses: actions/publish-action@v0.3.0 - with: - source-tag: ${{ github.ref_name }} + file_pattern: CHANGELOG.md \ No newline at end of file diff --git a/.github/workflows/tag-update-major-tag.yml b/.github/workflows/tag-update-major-tag.yml new file mode 100644 index 0000000..e51d20c --- /dev/null +++ b/.github/workflows/tag-update-major-tag.yml @@ -0,0 +1,27 @@ +name: Update major tag +on: + push: + tags: + - "v*" + +jobs: + create-changelog: + runs-on: ubuntu-latest + permissions: + contents: write + + steps: + - uses: actions/create-github-app-token@v1 + id: app-token + with: + app-id: ${{ secrets.DEPLOY_APP_ID }} + private-key: ${{ secrets.DEPLOY_APP_KEY }} + + - uses: actions/checkout@v4 + with: + token: ${{ steps.app-token.outputs.token }} + + - name: Update major tag to ${{ github.ref_name }} + uses: actions/publish-action@v0.3.0 + with: + source-tag: ${{ github.ref_name }}