* test: add failing tests for planner modular decomposition - Assert gsd-planner.md is under 45K after extraction (currently ~50K) - Assert three reference files exist (gap-closure, revision, reviews) - Assert planner contains reference pointers to each extracted file - Assert each reference file contains key content from the original mode * feat(agents): modular decomposition of gsd-planner.md to fix 50K char limit Extracts three non-standard mode sections from gsd-planner.md into dedicated reference files loaded on-demand, and calibrates the security scanner to use a per-file-type threshold (100K for agent source files vs 50K for user input). Structural changes: - Extract <gap_closure_mode> → get-shit-done/references/planner-gap-closure.md - Extract <revision_mode> → get-shit-done/references/planner-revision.md - Extract <reviews_mode> → get-shit-done/references/planner-reviews.md - Add <load_mode_context> step in execution_flow (conditional lazy loading) - gsd-planner.md: 50,112 → 45,352 chars (well under new 45K target) Security scanner fix: - Split agent file check: injection patterns (unchanged) + separate 100K size limit - The 50K strict-mode limit was designed for user-supplied input, not trusted source files - Agent files still have a size guard to catch accidental bloat Partially addresses #1495 * fix(tests): normalize CRLF before measuring planner file size Windows git checkouts add \r per line, inflating String.length by ~1150 chars for a 1,400-line file. The 45K threshold test failed on windows-latest because 45,352 chars (Linux) became 46,507 chars (Windows). Apply the same CRLF normalization pattern used in tests/reachability-check.test.cjs. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> --------- Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
6.2 KiB
6.2 KiB