Thanks for your interest in contributing! This guide covers everything you need to get started.
- Node.js >= 20
- pnpm >= 9
- Git with conventional commit knowledge
git clone https://github.com/sairam0424/CommandVault.git
cd CommandVault
pnpm install
pnpm build
pnpm test-
Create a branch from
develop:git checkout develop git checkout -b feat/your-feature
-
Make changes in the relevant package(s):
packages/core/— parsers, search, indexer, typespackages/cli/— terminal commandspackages/vscode/— VS Code extension
-
Build and test:
pnpm build pnpm test pnpm typecheck -
Commit using conventional commits:
feat(core): add new parser for X format fix(cli): handle empty search results gracefully perf(core): cache filtered Fuse.js instances -
Push and create a PR targeting
develop(notmain).
Format: <type>(<scope>): <description>
| Type | When |
|---|---|
feat |
New feature |
fix |
Bug fix |
perf |
Performance improvement |
refactor |
Code restructuring (no behavior change) |
test |
Adding or updating tests |
docs |
Documentation only |
chore |
Tooling, CI, dependencies |
Scopes: core, cli, vscode, or omit for cross-cutting changes.
packages/
├── core/ Engine: parsers, search, SQLite, watcher
├── cli/ Terminal: Commander.js commands
└── vscode/ Extension: TreeViews, webviews, commands
Build order matters: core must build before cli and vscode.
- Create
packages/cli/src/commands/your-command.ts - Export a
createYourCommand(): Commandfactory function - Register it in
packages/cli/src/index.ts - Support
--jsonoutput viaglobalOpts.json
- Create
packages/core/src/parsers/your-parser.ts - Return
ParserResult(entries + errors) - Register in
packages/core/src/parsers/index.ts - Call it from
Vault.scan()invault.ts - Add watch glob to
packages/core/src/watcher/index.ts - Add route to
packages/core/src/watcher/path-router.ts - Add tests in
packages/core/src/__tests__/
- Immutable objects — never mutate in-place
- No comments unless the "why" is non-obvious
- KISS — simplest solution that works
- Functions < 50 lines, nesting < 4 levels
- Prettier handles formatting (
pnpm format)
- Tests live next to source in
__tests__/directories - Use
vitestwithdescribe/it/expect - Integration tests run against real
~/.claude/(skipped if absent) - Target: > 80% coverage
- Title: short (< 70 chars), describes the change
- Body: summary bullets + test plan
- Target
develop, nevermaindirectly - All tests must pass before merge