diff --git a/.github/actions/setup/action.yml b/.github/actions/setup/action.yml index 7958314e..b4619aa9 100644 --- a/.github/actions/setup/action.yml +++ b/.github/actions/setup/action.yml @@ -12,8 +12,6 @@ runs: steps: - name: Install pnpm uses: pnpm/action-setup@v4 - with: - run-install: false - name: Setup node uses: actions/setup-node@v4 diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml new file mode 100644 index 00000000..56c5559d --- /dev/null +++ b/.github/workflows/release.yaml @@ -0,0 +1,31 @@ +name: Release + +on: + push: + branches: + - master + +jobs: + version: + runs-on: ubuntu-latest + steps: + - uses: googleapis/release-please-action@v4 + id: release-please + with: + release-type: node + outputs: + release_created: ${{ steps.release-please.outputs.release_created }} + + publish: + runs-on: ubuntu-latest + needs: [version] + if: ${{ needs.version.outputs.release_created }} + steps: + - uses: actions/checkout@v4 + + - uses: ./.github/actions/setup + + - name: Publish to NPM + run: pnpm publish + env: + NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}