Skip to content

Knowledge Silo: add --json/--output flags, tests, and report#37

Open
clockblocker wants to merge 1 commit intomasterfrom
nightshift/knowledge-silo
Open

Knowledge Silo: add --json/--output flags, tests, and report#37
clockblocker wants to merge 1 commit intomasterfrom
nightshift/knowledge-silo

Conversation

@clockblocker
Copy link
Copy Markdown
Owner

Summary

  • Added --json flag for machine-readable JSON output (CI/automation integration)
  • Added --output=<path> flag for writing reports directly to a file
  • Exported pure functions (classifyModule, computeBusFactor, detectSilos, aggregateByModule) as named exports for testability
  • Added 20 unit tests covering all four exported pure functions
  • Generated and committed .nightshift/knowledge-silo-report.md with the current analysis

Analysis Highlights

All 19 modules are flagged as HIGH risk — single contributor (clockblocker) owns 100% of commits across the entire src/ tree. Bus factor = 1 everywhere.

Test plan

  • bun test tests/unit/knowledge-silo.test.ts — 20/20 pass
  • bun scripts/knowledge-silo.ts --json — valid JSON output
  • bun scripts/knowledge-silo.ts --output=.nightshift/knowledge-silo-report.md — file written
  • biome check on changed files — clean
  • No new TypeScript errors introduced

Nightshift-Task: knowledge-silo
Nightshift-Ref: https://github.com/marcus/nightshift

🤖 Generated with Claude Code

…for knowledge-silo

- Add --json flag for machine-readable JSON output (CI integration)
- Add --output=<path> flag for writing directly to a file
- Export classifyModule, computeBusFactor, detectSilos, aggregateByModule
  as named exports for testability
- Guard main() with import.meta.main so imports don't trigger execution
- Add 20 unit tests covering all four pure functions
- Generate and commit .nightshift/knowledge-silo-report.md

Nightshift-Task: knowledge-silo
Nightshift-Ref: https://github.com/marcus/nightshift

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
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