publish on npmjs #44
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: publish on npmjs | |
| on: | |
| release: | |
| types: [created] | |
| workflow_dispatch: | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - run: sudo apt-get install -y android-tools-adb | |
| - uses: actions/checkout@v3 | |
| - uses: pnpm/action-setup@v2 | |
| with: | |
| version: 9.10.0 | |
| - name: Use Node.js 22 | |
| uses: actions/setup-node@v3 | |
| with: | |
| node-version: 22 | |
| registry-url: https://registry.npmjs.org/ | |
| cache: 'pnpm' | |
| - name: run pnpm install | |
| run: pnpm install --frozen-lockfile | |
| - run: pnpm run build | |
| - run: pnpm publish --no-git-checks | |
| env: | |
| NODE_AUTH_TOKEN: ${{secrets.npm_token}} |