Skip to content

Merge pull request #305 from korosuke613/renovate/actions-setup-node-4.x #82

Merge pull request #305 from korosuke613/renovate/actions-setup-node-4.x

Merge pull request #305 from korosuke613/renovate/actions-setup-node-4.x #82

name: release-please
on:
push:
branches:
- main
jobs:
release-please:
runs-on: ubuntu-latest
steps:
- uses: actions/create-github-app-token@v1
id: app-token
with:
app-id: ${{ vars.GH_APP_ID }}
private-key: ${{ secrets.GH_APP_PRIVATE_KEY }}
- uses: actions/checkout@v4
with:
token: ${{ steps.app-token.outputs.token }}
- uses: google-github-actions/release-please-action@db8f2c60ee802b3748b512940dde88eabd7b7e01 # v3.7.13
id: release
with:
release-type: node
package-name: typescript-action
token: ${{ steps.app-token.outputs.token }}
- name: tag major and minor versions
if: ${{ steps.release.outputs.release_created }}
run: |
git config user.name ${{ vars.GH_APP_NAME }}[bot]
git config user.email ${{ vars.GH_APP_NAME }}[bot]@users.noreply.github.com
git tag -d v${{ steps.release.outputs.major }} || true
git tag -d v${{ steps.release.outputs.major }}.${{ steps.release.outputs.minor }} || true
git push origin :v${{ steps.release.outputs.major }} || true
git push origin :v${{ steps.release.outputs.major }}.${{ steps.release.outputs.minor }} || true
git tag -a v${{ steps.release.outputs.major }} -m "Release v${{ steps.release.outputs.major }}"
git tag -a v${{ steps.release.outputs.major }}.${{ steps.release.outputs.minor }} -m "Release v${{ steps.release.outputs.major }}.${{ steps.release.outputs.minor }}"
git push origin v${{ steps.release.outputs.major }}
git push origin v${{ steps.release.outputs.major }}.${{ steps.release.outputs.minor }}