Skip to content

Commit 28eefcb

Browse files
committed
ci: skip workflow when only docs files change
Adding paths-ignore to push + pull_request triggers so iterations on the docs / README / changelog / license don't queue up CI runs that just regenerate docs/ and exit success. Workflow still fires the moment a code, test, or config file is in the diff alongside docs changes (paths-ignore is 'ALL files match' to skip). Patterns: - docs/** the build output - docs-src/** markdown handbook sources - site-src/** docs templates + assets - **/*.md any markdown anywhere (README, CHANGELOG, DESIGN, SECURITY, CONTRIBUTING, tests/README, …) - LICENSE text file, never code-related workflow_dispatch is unchanged — manual 'Run workflow' button can still kick a CI run on a docs-only commit when you want a final post-iteration check before merging.
1 parent 4da2da3 commit 28eefcb

1 file changed

Lines changed: 20 additions & 2 deletions

File tree

.github/workflows/ci.yml

Lines changed: 20 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,14 +13,32 @@ name: CI
1313
# or after a parser change.
1414

1515
on:
16+
# Skip pushes/PRs that only touch docs — repeated `make docs`
17+
# iterations or markdown tweaks shouldn't burn a runner. CI still
18+
# fires the moment a code/test/config file is in the diff
19+
# alongside the docs change. workflow_dispatch is always
20+
# available for manual override.
1621
pull_request:
1722
branches: [ main ]
23+
paths-ignore:
24+
- 'docs/**'
25+
- 'docs-src/**'
26+
- 'site-src/**'
27+
- '**/*.md'
28+
- 'LICENSE'
1829
push:
1930
branches: [ main ]
31+
paths-ignore:
32+
- 'docs/**'
33+
- 'docs-src/**'
34+
- 'site-src/**'
35+
- '**/*.md'
36+
- 'LICENSE'
2037
# Manual trigger only — used to fire the 8h soak and the fuzz
2138
# campaigns (each can spend hours of runner time, so we don't run
22-
# them on a cron). Hit the "Run workflow" button in GitHub Actions
23-
# to invoke.
39+
# them on a cron). Also lets you re-run the whole CI on a docs-only
40+
# commit when you're done iterating and want one final check. Hit
41+
# the "Run workflow" button in GitHub Actions to invoke.
2442
workflow_dispatch:
2543

2644
env:

0 commit comments

Comments
 (0)