feat: sync static-site docs verbatim, and allow syncing a ref by hand #574
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: Validate docs | |
| on: | |
| pull_request: | |
| paths: | |
| - 'docs/**/*.md' | |
| jobs: | |
| validate: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1 | |
| with: | |
| fetch-depth: 0 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: '22' | |
| cache: 'npm' | |
| - run: npm ci | |
| - name: Validate changed docs | |
| run: | | |
| BASE="${{ github.event.pull_request.base.sha }}" | |
| HEAD="${{ github.event.pull_request.head.sha }}" | |
| files=$(git diff --name-only --diff-filter=AM "$BASE" "$HEAD" -- 'docs/**/*.md') | |
| if [ -z "$files" ]; then | |
| echo "No docs files changed." | |
| exit 0 | |
| fi | |
| node scripts/validate.js $files |