Thank you for investing your time in contributing to CodeMind! 🧠
git clone https://github.com/vineethwilson15/codemind.git
cd codemind
pip install -r requirements.txt
pip install pre-commit ruff
pre-commit install # installs git hooks
cp .env.example .env
docker-compose up -d # Neo4j + Qdrant
pytest tests/unit/ # should pass immediately (no Docker needed)masteris the protected trunk — no direct pushes- Branch naming:
feat/<short-description>,fix/<short-description>,docs/<short-description>
- Pick or open an issue before writing code — agree on the approach first
- Create your branch from
master - Write code + tests (unit tests don't need Docker)
- Run checks locally before pushing:
ruff check . && ruff format . # lint + format pytest tests/unit/ # unit tests
- Open a PR — CI and CodeRabbit AI review will run automatically
Follow Conventional Commits:
feat: add tree-sitter Python parser
fix: handle UTF-8 decode errors in indexer
docs: clarify dual-store invariant in CONTRIBUTING
test: add integration test for GraphClient.upsert_file
| Rule | Where it applies |
|---|---|
| Always write Neo4j and Qdrant together | core/indexer/_write_atomically() |
All Neo4j writes must use MERGE, not CREATE |
core/graph/ |
CLI commands must be thin wrappers — logic lives in core/ |
cli/ |
All terminal output via rich.console.Console — never print() |
cli/ |
| Unit tests must mock all external clients | tests/unit/ |
Integration tests need @pytest.mark.integration |
tests/integration/ |
- Add a base class in
integrations/base.pyif the category is new - Create
integrations/<category>/<provider>.pywith one class per provider - Register the provider in
core/config.pyenv vars - Add unit tests mocking the provider's HTTP client
- Document required env vars in
.env.example
# Unit only (no Docker)
pytest tests/unit/ -m unit
# Integration (requires docker-compose up -d)
pytest tests/integration/ -m integrationThis project uses Ruff for both linting and formatting (configured in pyproject.toml). Run ruff check --fix . to auto-fix most issues.
Open a Discussion — we prefer discussions over issues for questions.