Skip to content

Commit

Permalink
fix: Fix automatic release with release-please bot (#486)
Browse files Browse the repository at this point in the history
  • Loading branch information
yorch authored Mar 31, 2022
1 parent 37d5517 commit 275fbc7
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions .github/workflows/release-please.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,27 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: google-github-actions/release-please-action@v3
id: release
with:
release-type: node
package-name: release-please-action
# Due to Github Actions design, releases created by this action won't trigger
# new Actions like `npm-publish.ym`, so we have to handle the npm publication here.
# More info:
# https://github.com/google-github-actions/release-please-action/issues/402
# https://github.com/googleapis/release-please/issues/1142
- uses: actions/checkout@v2
# These if statements ensure that a publication only occurs when
# a new release is created:
if: ${{ steps.release.outputs.release_created }}
- uses: actions/setup-node@v1
with:
node-version: 16
registry-url: https://registry.npmjs.org/
if: ${{ steps.release.outputs.release_created }}
- run: yarn install --frozen-lockfile
if: ${{ steps.release.outputs.release_created }}
- run: npm publish
env:
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}
if: ${{ steps.release.outputs.release_created }}

0 comments on commit 275fbc7

Please sign in to comment.