Private
Public Access
0
0
Commit Graph

3 Commits

Author SHA1 Message Date
ed 82468611ba feat(aggregate): add Inherits resolution + Non-directive context to preset parser 2026-07-05 14:14:22 -04:00
ed 5df938805e refactor(aggregate_directives): expose importable aggregate_directives(preset_path, max_chars, project_root) function
Wraps the body-building core in a public aggregate_directives() function that
returns the rendered string and raises FileNotFoundError/ValueError on errors.
The existing aggregate() CLI wrapper catches those and preserves the prior
stdout/file output behavior. parse_preset now accepts an optional root param so
directive paths inside the preset resolve against a caller-supplied
project_root instead of always REPO_ROOT. No behavior change for the CLI; the
new function is the API surface used by the upcoming MCP server tool.
2026-07-03 10:46:19 -04:00
ed 9d3222ddc0 feat(scripts): add scripts/aggregate_directives.py (presets -> clean body aggregation)
Aggregates v1.md bodies from a preset markdown into a single output stream.
NEVER reads meta.md (pollution fix). Stdlib-only; supports stdout and -o.

5 tests in tests/test_aggregate_directives.py cover: success path,
no-meta-md pollution, missing-file error, -o flag, no provenance leakage.
2026-07-03 00:03:51 -04:00