Summary
gitintel stats currently outputs human-readable tables. Adding a --format json flag would enable piping output to jq, dashboards, CI/CD pipelines, and other tooling.
What needs to happen
- Add a
--format flag to the stats subcommand (default: table, options: json, csv)
- Structure the JSON output to include all current stats fields
- Ensure backward compatibility — default output unchanged
- Add integration tests for JSON output parsing
Example output
{
"summary": {
"total_commits": 234,
"ai_commits": 47,
"ai_percentage": 20.1,
"agents": {
"claude-code": 31,
"cursor": 12,
"copilot": 4
}
},
"period": "30d",
"scanned_at": "2026-03-29T12:00:00Z"
}
Good first issue because
- Isolated to the output formatting layer
- Rust's
serde_json makes this straightforward
- Doesn't touch core scanning logic
Summary
gitintel statscurrently outputs human-readable tables. Adding a--format jsonflag would enable piping output tojq, dashboards, CI/CD pipelines, and other tooling.What needs to happen
--formatflag to thestatssubcommand (default:table, options:json,csv)Example output
{ "summary": { "total_commits": 234, "ai_commits": 47, "ai_percentage": 20.1, "agents": { "claude-code": 31, "cursor": 12, "copilot": 4 } }, "period": "30d", "scanned_at": "2026-03-29T12:00:00Z" }Good first issue because
serde_jsonmakes this straightforward