Manually install semantic-release as the intall step is faling in the CI #52
This file contains 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: NPM Publish | |
on: | |
push: | |
branches: | |
- master | |
- main | |
jobs: | |
release_build: | |
name: Release Build | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
persist-credentials: false | |
- id: setup | |
uses: ./.github/actions/setup_workspace | |
- run: pnpm type-check | |
- run: pnpm test | |
- run: pnpm build | |
- uses: actions/upload-artifact@v3 | |
with: | |
name: dist | |
path: dist | |
release_publish: | |
name: Release Publish | |
needs: release_build | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
persist-credentials: false | |
- id: setup | |
uses: ./.github/actions/setup_workspace | |
- uses: actions/download-artifact@v3 | |
with: | |
name: dist | |
path: dist | |
- run: ls -l | |
- run: ls -l dist/ | |
- name: Semantic Release | |
id: semantic_release | |
uses: cycjimmy/semantic-release-action@v4 | |
# with:# You can specify specifying version range for the extra plugins if you prefer. | |
# extra_plugins: | | |
# @semantic-release/git | |
# @semantic-release/github | |
# conventional-changelog-conventionalcommits | |
env: | |
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }} | |
NPM_TOKEN: ${{ secrets.NPM_TOKEN }} | |
- id: publish | |
if: steps.semantic_release.outputs.new_release_published == 'true' | |
uses: JS-DevTools/npm-publish@v3 | |
with: | |
token: ${{ secrets.NPM_TOKEN }} | |
package: ./dist/package.json |