Contributing
devgrep welcomes issues and pull requests. Keep changes offline-first, terminal-first, and dependency-conscious.
Full guidelines live in CONTRIBUTING.md in the main repository. This page summarizes the workflow for documentation readers.
Local development
sh
git clone https://github.com/aasixh/devgrep
cd devgrep
make build
./bin/devgrep versionRunning tests
sh
make test # race detector + coverage
make lint # golangci-lint or go vet
make bench # includes 100k search benchmarkFormatting
Follow standard Go formatting (gofmt). Keep packages focused — new indexers implement internal/indexer.Indexer without widening cmd/ unnecessarily.
Architecture philosophy
- Four layers: indexers → storage → search → CLI/TUI
- Shared ignore and walk logic in internal/utils
- SQLite as single source of truth for documents and watch state
- New sources plug in via Indexer — commands stay thin
Contributing safely
- Never add network calls, telemetry, or cloud dependencies
- Index only local files; document privacy implications in PRs
- Test risky path guards (/, ~) and non-interactive --yes behavior
- Run make test and make lint before opening a PR
Proposing features
Open an issue describing the workflow problem, not the implementation. Good fits: new local indexers, ranking tweaks, TUI ergonomics, benchmark coverage. Poor fits: hosted search, AI summarization, Electron UI, background daemons.
UX philosophy
- Unix-like: composable plain output, sensible defaults, minimal flags
- Terminal-native: Bubble Tea TUI, lipgloss, keyboard-first navigation
- Fail clearly: human-readable errors via utils.HumanizeError
- Safe defaults: dry-run, path confirmation, ignore rules for heavy trees
Good first contributions
- New local source indexers
- Ranking improvements
- Terminal theme polish
- Shell-specific history metadata
- Performance benchmarks