13 runs-on: ubuntu-latest
14 if: github.repository == 'poolifier/poolifier'
21 release_created: ${{ steps.release.outputs.release_created }}
24 - uses: googleapis/release-please-action@v4
27 token: ${{ secrets.WORKFLOW_TOKEN }}
28 config-file: .github/release-please/config.json
29 manifest-file: .github/release-please/manifest.json
33 runs-on: ubuntu-latest
34 if: needs.release-please.outputs.release_created
38 uses: actions/checkout@v4
41 uses: pnpm/action-setup@v4
44 uses: actions/setup-node@v4
49 - name: Install Dependencies
50 run: pnpm install --ignore-scripts --frozen-lockfile
52 - name: Tests & Coverage
60 - name: Production Build
65 runs-on: ubuntu-latest
73 uses: actions/checkout@v4
76 uses: actions/setup-node@v4
80 - name: Read package.json version
82 uses: jaywcjlove/github-action-package@main
84 - name: Publish Release
85 if: ${{ contains(steps.package-version.outputs.version, '-') == false }}
86 run: npx jsr publish --allow-dirty
90 runs-on: ubuntu-latest
94 uses: actions/checkout@v4
97 uses: pnpm/action-setup@v4
100 uses: actions/setup-node@v4
103 registry-url: https://registry.npmjs.org/
106 - name: Install Dependencies
107 run: pnpm install --ignore-scripts --frozen-lockfile
109 - name: Read package.json version
111 uses: jaywcjlove/github-action-package@main
113 - name: Publish Release
114 if: ${{ contains(steps.package-version.outputs.version, '-') == false }}
115 run: pnpm publish --no-git-checks
117 NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
119 - name: Publish Pre-Release
120 if: ${{ contains(steps.package-version.outputs.version, '-') == true && contains(steps.package-version.outputs.version, '-beta') == false }}
121 run: pnpm publish --no-git-checks --tag next
123 NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
125 - name: Publish Beta Release
126 if: ${{ contains(steps.package-version.outputs.version, '-beta') == true }}
127 run: pnpm publish --no-git-checks --tag beta
129 NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
131 publish-documentation:
132 needs: [publish-npm, publish-jsr]
133 runs-on: ubuntu-latest
137 uses: actions/checkout@v4
140 uses: pnpm/action-setup@v4
142 - name: Setup Node.js
143 uses: actions/setup-node@v4
148 - name: Generate documentation
150 pnpm install --ignore-scripts --frozen-lockfile
154 if: github.ref == 'refs/heads/${{ github.event.repository.default_branch }}'
156 COMMIT_MESSAGE: 'docs: publish documentation'
157 COMMIT_AUTHOR: Documentation Bot
158 COMMIT_EMAIL: documentation-bot@users.noreply.github.com
160 git config --local user.name "${{ env.COMMIT_AUTHOR }}"
161 git config --local user.email "${{ env.COMMIT_EMAIL }}"
164 git commit -a -m "${{ env.COMMIT_MESSAGE }}"
167 if: github.ref == 'refs/heads/${{ github.event.repository.default_branch }}'
168 uses: CasperWA/push-protected@v2
170 token: ${{ secrets.GH_TOKEN_PROTECTED }}
171 branch: ${{ github.event.repository.default_branch }}