Publish Library package #15
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 Library package | |
| on: | |
| workflow_dispatch: | |
| env: | |
| FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true | |
| permissions: | |
| contents: write | |
| id-token: write | |
| jobs: | |
| publish: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v6 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v6 | |
| with: | |
| node-version: "24.x" | |
| - name: Setup Bun | |
| uses: oven-sh/setup-bun@v2 | |
| - name: Install dependencies | |
| run: bun install | |
| - name: Build | |
| run: bun run build | |
| - name: Test | |
| run: bun run test | |
| - name: Copy README | |
| run: cp README.md packages/streamdeck-react/README.md | |
| - name: Copy LICENSE | |
| run: cp LICENSE packages/streamdeck-react/LICENSE | |
| - name: Publish | |
| run: npm publish --provenance --access public | |
| working-directory: packages/streamdeck-react | |
| - name: Create GitHub Release | |
| run: | | |
| version=$(node -p "require('./packages/streamdeck-react/package.json').version") | |
| gh release create "@fcannizzaro/streamdeck-react@${version}" --title "@fcannizzaro/streamdeck-react@${version}" --generate-notes | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |