Merge remote-tracking branch 'origin/main' #197
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Release and Publish | |
| on: | |
| push: | |
| branches: | |
| - main | |
| # Frontend source is delivered by chatgpt-plugin, not the npm package. | |
| # A frontend-only commit therefore must not create a release PR or publish. | |
| paths-ignore: | |
| - "frontend/**" | |
| permissions: | |
| contents: write | |
| pull-requests: write | |
| jobs: | |
| release-please: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: googleapis/release-please-action@v4 | |
| id: release | |
| with: | |
| release-type: node | |
| - uses: actions/checkout@v4 | |
| if: ${{ steps.release.outputs.release_created }} | |
| - uses: actions/setup-node@v4 | |
| if: ${{ steps.release.outputs.release_created }} | |
| with: | |
| node-version: 20 | |
| registry-url: "https://registry.npmjs.org" | |
| - uses: pnpm/action-setup@v4 | |
| if: ${{ steps.release.outputs.release_created }} | |
| with: | |
| version: 9 | |
| - run: pnpm install | |
| if: ${{ steps.release.outputs.release_created }} | |
| - run: pnpm run prepublishOnly | |
| if: ${{ steps.release.outputs.release_created }} | |
| - run: pnpm publish --access public --no-git-checks --//registry.npmjs.org/:_authToken=${NODE_AUTH_TOKEN} | |
| env: | |
| NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} | |
| if: ${{ steps.release.outputs.release_created }} |