Version Packages #4
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: Generate Docs | |
| on: | |
| pull_request: | |
| types: [opened, synchronize] | |
| branches: | |
| - main | |
| jobs: | |
| generate-docs: | |
| if: github.actor == 'github-actions[bot]' | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| token: ${{ secrets.CHANGESETS_GH_TOKEN }} | |
| - uses: pnpm/action-setup@v4 | |
| with: | |
| version: 10 | |
| run_install: true | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: 20.x | |
| - run: pnpm install | |
| - name: Build Docs | |
| run: pnpm docs:build | |
| - name: Commit and push docs | |
| run: | | |
| git config user.name "github-actions[bot]" | |
| git config user.email "github-actions[bot]@users.noreply.github.com" | |
| git add docs | |
| git commit -m "chore: update docs [skip ci]" || echo "No changes to commit" | |
| git push |