Release v0.0.58 #4
Workflow file for this run
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: NPM Publish | |
| on: | |
| release: | |
| types: [created] | |
| permissions: | |
| id-token: write | |
| contents: read | |
| jobs: | |
| test: | |
| uses: ./.github/workflows/node.js.yml | |
| publish-npm: | |
| needs: test | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Set up Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: 22 | |
| registry-url: https://registry.npmjs.org/ | |
| - name: Install PNPM | |
| uses: pnpm/action-setup@v4 | |
| with: | |
| version: 9 | |
| run_install: false | |
| - name: Update npm | |
| shell: bash | |
| run: npm install -g [email protected] | |
| - name: Enable Corepack | |
| run: corepack enable | |
| - name: Get PNPM store directory | |
| shell: bash | |
| run: | | |
| echo "STORE_PATH=$HOME/.local/share/pnpm/store" >> $GITHUB_ENV | |
| - name: Setup PNPM cache | |
| uses: actions/cache@v4 | |
| with: | |
| path: ${{ env.STORE_PATH }} | |
| key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} | |
| restore-keys: | | |
| ${{ runner.os }}-pnpm-store- | |
| - name: Extract tag | |
| id: get_tag | |
| run: echo "TAG=${GITHUB_REF#refs/tags/}" >> $GITHUB_OUTPUT | |
| - name: Install dependencies | |
| run: pnpm install --no-frozen-lockfile | |
| - name: Run publish script | |
| run: ./scripts/publish.sh ${{ steps.get_tag.outputs.TAG }} | |
| - name: Upload release assets | |
| uses: softprops/action-gh-release@v1 | |
| with: | |
| files: | | |
| dist/bundle.js | |
| dist/bundle.min.js |