DevBrief: developer CLI for project situational awareness — fetches structured data from a GitHub repo and generates a human-readable brief via Claude AI.
Distribution: PyPI (devbrief) + crates.io (devbrief-core)
Stack: Python (uv) + Rust (maturin/PyO3). No React, no Docker, no webpack.
| Task | Command |
|---|---|
| Install deps | uv sync |
| Run tests | uv run pytest |
| Lint | uv run ruff check src/ tests/ |
| Format | uv run ruff format src/ tests/ |
| Type check | uv run mypy src/ |
| Rust tests | PYO3_BUILD_EXTENSION_MODULE=1 cargo test --manifest-path rust/Cargo.toml |
| Build wheel | maturin develop |
- Credential resolution: env var →
.envfile →~/.config/devbrief/config.toml→ keychain (future). Implemented indevbrief.core.credentials. - Cache key:
sha256(url + commit_sha)→~/.cache/devbrief/ - Config file:
~/.config/devbrief/config.toml, permissions600on write. - Model: always resolved via
resolve_model()— never hardcoded in command files. - Rust extension:
devbrief envonly. If unavailable at runtime, fall back to Python. - Assets:
assets/excluded from PyPI wheel via[tool.maturin] exclude.
| Subcommand | Status | Notes |
|---|---|---|
| devbrief repo | LIVE | v0.3.2, SHA-keyed cache, --no-cache/--refresh |
| devbrief auth | LIVE | v0.2.0, key validation, config write/read/clear, 600 perms |
| devbrief logs | LIVE | v0.3.0, FastAPI+HTMX polling dashboard, ring buffer, file/stdin |
| devbrief env | LIVE | v0.4.2, gitignore audit + .env drift + secret scan (Rust) |
| devbrief api | PLANNED | |
| devbrief infra | PLANNED | |
| devbrief pr | PLANNED |
All subcommands through v0.4.2 are LIVE. Next action: await spec card before touching any subcommand.
- CI:
ci.ymlruns lint + type-check + test on every PR and push tomain. - Release:
release.ymlon git tagv*— wheels only (no sdist), PyPI OIDC. - Versioning: semver. Python and Rust share version. Update
pyproject.toml+ tag simultaneously.
- Do not push to
mainor merge PRs — Sebastien reviews. - Do not hardcode model strings — always use
resolve_model(). - Do not use
print()in command handlers — use Rich. - Do not commit
.envorconfig.toml. - Do not build
sdist— Rust extension requires Rust toolchain; wheels only. - Do not implement new subcommands without a spec card.
See .claude/rules/ for enforced coding conventions:
python.md— Python conventions, async, typing, Rich, model resolutionrust.md— PyO3/maturin, clippy, cargo test setuptesting.md— pytest structure, cargo test, credential mockinggit.md— branch naming, conventional commits, PR discipline, hard stops