Skip to content

feat: v2.2.0 — auto-fix, diff command, wildcard re-exports#47

Merged
corvid-agent merged 4 commits intomainfrom
feat/v2.2-improvements
Mar 25, 2026
Merged

feat: v2.2.0 — auto-fix, diff command, wildcard re-exports#47
corvid-agent merged 4 commits intomainfrom
feat/v2.2-improvements

Conversation

@corvid-agent
Copy link
Collaborator

@corvid-agent corvid-agent commented Mar 25, 2026

Summary

Three new features that close the loop on spec maintenance:

  • --fix flagspecsync check --fix auto-adds undocumented exports as stub rows in Public API tables. Creates the section if missing. Never duplicates existing entries. Works with --json.
  • diff commandspecsync diff [ref] shows exports added/removed since a git ref. Human-readable and JSON output. Essential for code review and release notes.
  • Wildcard re-export resolutionexport * from './module' in TypeScript barrel files now resolves and validates the re-exported symbols. Namespace exports (export * as Ns) detected as a single entry. Depth-limited to one level.

Quality:

  • 131 tests (57 unit + 74 integration), all passing
  • 13 specs at 100% coverage, all passing
  • Clippy clean
  • 12 new integration tests covering all three features
  • Updated cli.spec.md and exports.spec.md with full behavioral examples and invariants

Release prep:

  • Version bumped to 2.2.0
  • CHANGELOG.md updated with full v2.2.0 entry
  • README updated: Quick Start, CLI Reference, Flags, new Auto-Fix & Diff section, wildcard re-exports in language table

Test plan

  • CI passes (cargo test + clippy + fmt)
  • specsync check passes on own specs (13/13)
  • specsync check --fix adds stubs without duplicating existing entries
  • specsync diff HEAD~1 shows the expected added/removed exports
  • Wildcard re-exports resolve correctly in TS barrel files
  • README renders correctly on GitHub

🤖 Generated with Claude Code

@corvid-agent corvid-agent changed the title feat: add wildcard re-exports, --fix flag, diff command, and quality improvements feat: v2.2.0 — auto-fix, diff command, wildcard re-exports Mar 25, 2026
corvid-agent and others added 4 commits March 25, 2026 07:51
…improvements

- TypeScript: support `export * from` wildcard re-exports (resolves sibling
  files), `export * as Ns` namespace re-exports, and `export default` declarations
- New `--fix` flag on `check` command auto-adds undocumented exports to spec
  Public API tables as stubs
- New `diff` command shows export changes since a git ref, useful for CI/PR
  comments to detect spec drift
- Config validation: warn on unknown keys in specsync.json and .specsync.toml
- Fix: replace `.expect()` panic in `init` with proper error message and exit
- Add unit tests for validator.rs (cross-project refs, levenshtein, spec
  validation) and scoring.rs (TODO counting, section content, project scores)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
… update specs

Add 12 new integration tests covering the three features from the previous
commit that had zero test coverage:

- --fix flag: 4 tests (adds exports, no duplicates, creates missing section, JSON mode)
- diff command: 4 tests (new exports, removed exports, no changes, human-readable output)
- wildcard re-exports: 4 tests (barrel file, fix+wildcard, namespace re-export, depth limit)

Update CLI and exports specs to document --fix, diff, and wildcard re-export
behavior with invariants, behavioral examples, and public API entries.

131 tests pass (57 unit + 74 integration), all 13 specs pass, clippy clean.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Bump version to 2.2.0 in Cargo.toml
- Add v2.2.0 changelog entry covering --fix, diff, and wildcard re-exports
- Update README: new commands in Quick Start, CLI Reference, Flags table
- Add Auto-Fix & Diff section with usage examples and workflow guidance
- Document wildcard re-export resolution in Supported Languages table
- Add diff JSON output shape example

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@corvid-agent corvid-agent force-pushed the feat/v2.2-improvements branch from b273d84 to 58236ff Compare March 25, 2026 14:52
@corvid-agent corvid-agent merged commit 8c90ebe into main Mar 25, 2026
6 of 7 checks passed
@corvid-agent corvid-agent deleted the feat/v2.2-improvements branch March 25, 2026 14:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant