Commit 93924be
feat: Auto-manage QA runtime cache excludes in project root .gitignore
Defence-in-depth for the QA runtime cache tracking class of bug:
misconfigured tools (e.g. PHPUnit with the default `cacheDirectory`)
write cache dirs into folders that happen to be tracked, and those
caches silently end up in git.
prepareDirectories.inc.bash now appends a marked, idempotent block to
the consuming project's root .gitignore with anywhere-in-tree patterns
for every QA tool cache we know about:
**/.phpunit.cache/
**/.qa-lock/
**/.php-cs-fixer.cache
**/.php_cs.cache
**/.rector.cache/
**/phpstan-result.json
The block is guarded by BEGIN/END markers so re-runs are no-ops and
manual edits to the rest of the file are preserved. The lib itself
picks this up through its own self-QA runs, so the same patterns are
already committed to this repo's top-level .gitignore.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>1 parent d211348 commit 93924be
2 files changed
Lines changed: 54 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
0 commit comments