fix: accept boolean and number types for manifest default field #39
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 Docs | |
| on: | |
| push: | |
| branches: [main] | |
| paths: | |
| - 'docs/**' | |
| - 'spec/**' | |
| - 'schema/**' | |
| - 'README.md' | |
| - 'CONTRIBUTING.md' | |
| - '.github/workflows/docs.yml' | |
| pull_request: | |
| branches: [main] | |
| workflow_dispatch: | |
| permissions: | |
| contents: read | |
| deployments: write | |
| jobs: | |
| changes: | |
| name: Detect changes | |
| if: github.event_name == 'pull_request' | |
| runs-on: ubuntu-latest | |
| outputs: | |
| should_run: ${{ steps.filter.outputs.docs }} | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: dorny/paths-filter@v3 | |
| id: filter | |
| with: | |
| filters: | | |
| docs: | |
| - 'docs/**' | |
| - 'spec/**' | |
| - 'schema/**' | |
| - 'README.md' | |
| - 'CONTRIBUTING.md' | |
| - '.github/workflows/docs.yml' | |
| build-and-deploy: | |
| name: Build and Deploy Docs | |
| needs: changes | |
| if: | | |
| github.event_name == 'push' || | |
| github.event_name == 'workflow_dispatch' || | |
| needs.changes.outputs.should_run == 'true' | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 # Full history needed for lastUpdated | |
| - uses: pnpm/action-setup@v4 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: '20' | |
| cache: 'pnpm' | |
| - name: Install dependencies | |
| run: pnpm install --frozen-lockfile --filter @rep-protocol/docs... | |
| - name: Build docs | |
| run: pnpm docs:build | |
| - name: Install wrangler | |
| run: npm install -g wrangler | |
| - name: Deploy to Cloudflare Pages | |
| if: github.event_name == 'push' && github.ref == 'refs/heads/main' | |
| uses: cloudflare/wrangler-action@v3 | |
| with: | |
| apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }} | |
| accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }} | |
| command: pages deploy docs/dist --project-name=rep-docs --branch=main | |
| - name: Deploy preview | |
| if: github.event_name == 'pull_request' | |
| uses: cloudflare/wrangler-action@v3 | |
| with: | |
| apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }} | |
| accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }} | |
| command: pages deploy docs/dist --project-name=rep-docs --branch=${{ github.head_ref }} | |
| docs-status: | |
| name: Docs Status | |
| if: always() && github.event_name == 'pull_request' | |
| needs: [build-and-deploy] | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Check result | |
| run: | | |
| if [ "${{ needs.build-and-deploy.result }}" = "failure" ] || [ "${{ needs.build-and-deploy.result }}" = "cancelled" ]; then | |
| echo "Docs CI failed or was cancelled" | |
| exit 1 | |
| fi | |
| echo "Docs CI passed or was skipped" |