feat: add support for @rspress/core@2.0.0-rc.8
#23
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: Deploy PR previews | |
| on: | |
| pull_request: | |
| types: | |
| - opened | |
| - reopened | |
| - synchronize | |
| - closed | |
| concurrency: preview-${{ github.ref }} | |
| jobs: | |
| deploy-preview: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: write | |
| pull-requests: write | |
| pages: write | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| with: | |
| persist-credentials: true | |
| - name: Setup pnpm | |
| uses: pnpm/action-setup@v4 | |
| with: | |
| version: 9.12.2 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version-file: .nvmrc | |
| cache: 'pnpm' | |
| - name: Install dependencies | |
| if: github.event.action != 'closed' | |
| run: pnpm install --frozen-lockfile | |
| - name: Build project packages | |
| if: github.event.action != 'closed' | |
| run: pnpm run build | |
| - name: Build tester package | |
| if: github.event.action != 'closed' | |
| working-directory: packages/tester | |
| env: | |
| NODE_ENV: production | |
| RSPRESS_BASE: /rspress-theme/pr-preview/pr-${{ github.event.number }}/ | |
| run: pnpm run build | |
| - name: Deploy preview | |
| uses: rossjrw/pr-preview-action@v1 | |
| with: | |
| source-dir: packages/tester/doc_build | |
| preview-branch: gh-pages | |
| qr-code: true | |
| wait-for-pages-deployment: true |