diff --git a/.github/workflows/mintlify-quality.yml b/.github/workflows/mintlify-quality.yml index 45e9713d7e..50b460d56e 100644 --- a/.github/workflows/mintlify-quality.yml +++ b/.github/workflows/mintlify-quality.yml @@ -5,9 +5,31 @@ on: branches: - main - docs-next + paths: &docs-paths + - 'docs-site' + - 'docs-site/**' + - 'docs' + - 'docs/**' + - 'mintlify-native' + - 'mintlify-native/**' + - 'patches' + - 'patches/**' + - 'tests/**' + - 'src/**' + - 'scripts/**' + - '.gitattributes' + - '.gitignore' + - '.prettierrc' + - '.prettierignore' + - 'package.json' + - 'package-lock.json' + - 'tsconfig.json' + - 'docusaurus.config.js' + - '.github/workflows/**' push: branches: - docs-next + paths: *docs-paths workflow_dispatch: permissions: diff --git a/.github/workflows/test-deploy.yml b/.github/workflows/test-deploy.yml index 94833d1422..d3e2e8c2c7 100644 --- a/.github/workflows/test-deploy.yml +++ b/.github/workflows/test-deploy.yml @@ -27,5 +27,8 @@ jobs: - name: Install dependencies run: npm ci + - name: Check preserved site files + run: node --test --test-name-pattern='repository retains' scripts/site-boundary.test.mjs + - name: Test build website run: npm run build diff --git a/scripts/README.md b/scripts/README.md index b1b8eaff7a..763efa891c 100644 --- a/scripts/README.md +++ b/scripts/README.md @@ -17,6 +17,23 @@ workflows use it. `npm run check:mintlify`, run by the [quality workflow](../.github/workflows/mintlify-quality.yml), includes the root regression suites and freshness checks; it does not build or deploy edge infrastructure. +The quality workflow uses GitHub's native `paths` filters for PRs and pushes. +Directory-wide patterns cover docs sources, `patches/`, `src/`, `scripts/`, +`tests/`, and `.github/workflows/`, alongside the listed root dependencies and +configuration. This intentionally includes non-docs edits within those directories +so new inputs are covered without maintaining per-file lists. The shared path +list lives directly in the workflow. +Manual runs remain unfiltered. GitHub's native diff limits apply; use a manual +run for unusually large changes. Keep this path-filtered status optional, since +GitHub leaves skipped workflow checks pending. + +The always-running [deployment workflow](../.github/workflows/test-deploy.yml) +runs the existing file-preservation test from `site-boundary.test.mjs` on every +PR to `main` or `docs-next`, so deleting or moving required website files cannot +bypass the check when docs quality is skipped. +Blog and static-asset-only changes do not trigger the full docs suite. +Nightly/manual source updaters remain unchanged. + | Files | Role and root commands | | --- | --- | | `prepare-agent-content.mjs`, `agent-content.mjs`, `validate-agent-content.mjs` | Prepare/check the curated root LLM index, website-only bundle, and Home/Project/Community Markdown: `npm run build:agent-content`, `npm run check:agent-content`. |