Skip to content

Commit a109810

Browse files
committed
docs: v1.3.0 — --diff flag, watch debounce, watchDebounce config key
- CHANGELOG: v1.3.0 entry with full Added/Changed/Validation gate sections - README: CLI reference note updated to v1.3 - TIMELINE: v1.3 status → SHIPPED
1 parent 3179ebe commit a109810

3 files changed

Lines changed: 34 additions & 2 deletions

File tree

CHANGELOG.md

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,38 @@ Format: [Semantic Versioning](https://semver.org/)
66

77
---
88

9+
## [1.3.0] — 2026-04-03
10+
11+
### Added
12+
- **`--diff` CLI flag** — generates context only for files changed in the current git working tree (`git diff HEAD --name-only`). Useful in CI and pre-review workflows where you only want signatures for files you've touched.
13+
- **`--diff --staged` variant** — restricts context to files in the git staging area only (`git diff --cached --name-only`). Ideal as a pre-commit check.
14+
- **Smart fallback** — both `--diff` modes automatically fall back to a full `runGenerate` when: outside a git repo, no changed files, or all changed files are outside tracked `srcDirs`. No silent failures.
15+
- **`--diff --report`** — when both flags are used together, prints a side-by-side comparison of diff-mode vs full-mode token counts and savings.
16+
- **`watchDebounce` config key** — new key in `gen-context.config.json` (default: `300`) controls the debounce delay (ms) between file-system events and regeneration in watch mode. Configurable per project.
17+
- **`test/integration/diff.test.js`** — 6 integration tests covering all diff-mode scenarios:
18+
- Diff-only output excludes unchanged files
19+
- `--staged` excludes unstaged modifications
20+
- Empty diff fallback to full generate
21+
- Non-git-repo fallback
22+
- Changed files outside srcDirs fallback
23+
- Multiple changed files all appear in output
24+
25+
### Changed
26+
- Watch mode debounce reduced from **500 ms → 300 ms** (default). Now reads `config.watchDebounce || 300` — fully configurable.
27+
- `gen-context.js` VERSION bumped to `1.3.0`
28+
- MCP server version bumped to `1.3.0`
29+
- `package.json` version bumped to `1.3.0`
30+
- `src/config/defaults.js` — added `watchDebounce: 300` key
31+
32+
### Validation gate
33+
- `node gen-context.js --version``1.3.0`
34+
- `node gen-context.js --diff` on a repo with changes → output contains only changed-file sigs ✔
35+
- `node gen-context.js --diff --staged` → output contains only staged-file sigs ✔
36+
- `node test/integration/diff.test.js` → 6/6 pass ✔
37+
- `node test/run.js` → 21/21 extractor tests pass ✔
38+
39+
---
40+
941
## [1.2.0] — 2026-04-02
1042

1143
### Added

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ npx repomix --compress # deep dive sessions
8787

8888
## CLI reference
8989

90-
> **Note:** `node gen-context.js`, `--watch`, `--setup`, `--report`, `--mcp`, `--routing`, `--diff`, and `--init` are live in v1.2.
90+
> **Note:** `node gen-context.js`, `--watch`, `--setup`, `--report`, `--mcp`, `--routing`, `--diff`, and `--init` are live in v1.3.
9191
> Features marked `(v0.x)` or `(v1.x)` were added incrementally — see [CHANGELOG.md](CHANGELOG.md) for when each shipped.
9292
9393
```

TIMELINE.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -700,7 +700,7 @@ node test/run.js
700700
---
701701

702702
## v1.3 — `--diff` flag + watch debounce
703-
**Status: 📋 PLANNED**
703+
**Status: ✅ SHIPPED — v1.3.0**
704704
**Duration: 2 days | Owner: Platform**
705705

706706
### What ships

0 commit comments

Comments
 (0)