Skip to content

Commit 5a58e5f

Browse files
author
Flamehaven CI
committed
Default spicy on; add --no-spicy option and docs
1 parent 4a271a8 commit 5a58e5f

File tree

3 files changed

+8
-6
lines changed

3 files changed

+8
-6
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
1515
- HF demo import path includes `src` so `dir2md` imports resolve in Spaces.
1616
- Lint/test cleanup after refactor (ruff + pytest green).
1717
- Default excludes now drop cache/venv noise (`.pytest_cache_local`, `.ruff_cache`, `venv_clean`) for cleaner blueprints out of the box.
18+
- Spicy is now enabled by default; `--no-spicy` disables, `--spicy-strict` enforces failure on high/critical.
1819

1920
### Documentation
2021
- Updated README/demo metadata (Spicy branding, HF front matter); pending: scrub remaining Pro/license mentions in docs.

README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ Dir2md analyzes directory structures and generates comprehensive markdown docume
3838
- **[*] Fast preset**: `--fast` builds tree + manifest only (no file reads) for ultra-light contexts.
3939
- **[o] AI-friendly defaults**: `--ai-mode` with capped budgets, stats, manifest on; `--query` ranks files and injects snippets.
4040
- **[+] Dual outputs by default**: Generates human `md` and LLM-friendly `jsonl` together unless you choose `--output-format`.
41-
- **[#] Spicy risk report**: `--spicy` adds 5-level findings to md/json/jsonl/manifest; `--spicy-strict` fails on high/critical.
41+
- **[#] Spicy risk report**: On by default (`--spicy`); disable with `--no-spicy`. Adds 5-level findings to md/json/jsonl/manifest; `--spicy-strict` fails on high/critical.
4242
- **[T] CLI polish**: `[LEVEL]` status lines, `--progress none|dots|full`, timestamped `*_blueprint[_spicy]_YYYYMMDD` filenames.
4343
- **[&] Architecture**: Introduced `walker.py`, `selector.py`, `renderer.py`, `orchestrator.py` to reduce `core.py` coupling.
4444
- **[W] Release**: Added PyPI/TestPyPI release workflow and Docker usage notes.
@@ -331,10 +331,10 @@ Raw code slice for local agents:
331331
dir2md . --preset raw --masking basic --budget-tokens 4000
332332
```
333333

334-
### Spicy risk report
335-
- Enable spicy findings: `--spicy`
336-
- Enforce failure on high/critical: `--spicy --spicy-strict` (exit code 2)
337-
- Outputs:
334+
### Spicy risk report
335+
- Spicy on by default. Disable with `--no-spicy`
336+
- Enforce failure on high/critical: `--spicy --spicy-strict` (exit code 2)
337+
- Outputs:
338338
- `md` (human-friendly): includes ?쏶picy??section
339339
- `json`/`jsonl`/manifest (LLM-friendly): `spicy.score`, `spicy.counts`, `spicy.findings[]`
340340
Severity levels: ok, warn, risk, high, critical.

src/dir2md/cli.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -291,7 +291,8 @@ def main(argv: list[str] | None = None) -> int:
291291
ap.add_argument("--mask-pattern-file", action="append", dest="mask_pattern_files", help="Load custom mask regex patterns from file (JSON array or newline separated list). Supports file:// URIs.")
292292
ap.add_argument("--output-format", choices=["md", "json", "jsonl", "both"], help="Output format: md (human), json/jsonl (LLM); default produces md+jsonl")
293293
ap.add_argument("--progress", choices=["full", "dots", "none"], help="Progress verbosity for CLI output (default: dots)")
294-
ap.add_argument("--spicy", action="store_true", help="Enable spicy risk report (severity counts and findings)")
294+
ap.add_argument("--spicy", dest="spicy", action="store_true", default=True, help="Enable spicy risk report (default: on)")
295+
ap.add_argument("--no-spicy", dest="spicy", action="store_false", help="Disable spicy risk report")
295296
ap.add_argument("--spicy-strict", action="store_true", help="Exit non-zero if spicy finds high/critical findings")
296297

297298
ap.add_argument("-V", "--version", action="version", version=f"dir2md {__version__}")

0 commit comments

Comments
 (0)