{
  "slug": "jj-diff-stat-limits-stat-bar-width-d71aeaa31f28",
  "title": "jj diff.stat limits stat bar width",
  "tools": [
    "jj"
  ],
  "tags": [
    "agent"
  ],
  "introduced_at": "2026-08-06T01:42:10.000Z",
  "announced_at": "2026-08-06T01:42:10.000Z",
  "effective_at": null,
  "date_basis": "source-publication",
  "status": "unknown",
  "how": {
    "incantation": "When reviewing diff statistics in a narrow layout, set `diff.stat.max-bar-width` to cap the `++--` bar while using `--stat`. For template output, `diff.stat()` accepts an optional `max_bar_width` argument for the same effect.",
    "examples": [
      "[diff.stat]\nmax-bar-width = 10\n\njj show --stat",
      "jj diff -T 'diff.stat(max_bar_width=10)'"
    ],
    "gotchas": [
      "Version: v0.44.0",
      "diff.stat.max-bar-width: Maximum character width of the `++--` bar in diff stat output; without it, the bar uses remaining available space, with a minimum of 30% of total width.",
      "--stat: Enables diff stat output; the release note says the new config option applies when using it.",
      "diff.stat() max_bar_width: Optional second positional or named integer argument limiting the maximum character length of the `++--` bar. The template docs also list an optional first `width` argument; they do not state that the arguments are mutually exclusive.",
      "The `max_bar_width` argument to `diff.stat()` is optional and may be positional or named."
    ]
  },
  "why_it_matters": "When reviewing diff statistics in a narrow output layout, limit the `++--` bar width.",
  "sources": [
    "https://github.com/jj-vcs/jj/releases/tag/v0.44.0",
    "https://github.com/jj-vcs/jj/blob/main/docs/config.md",
    "https://github.com/jj-vcs/jj/blob/main/docs/templates.md",
    "https://github.com/jj-vcs/jj/discussions/9925"
  ],
  "rank": 0.92016,
  "judge": {
    "publish": true,
    "judge_model": "codex-cli/gpt-6-luna+typesafe/jev-1.13.0",
    "prompt_version": "extract-v7+enrich-v2+judge-v2x3+jev-publish-v1"
  },
  "review_state": "approved",
  "provenance": {
    "run_id": "wave1b-tools-20261017",
    "verdict_id": "wave1b-tools-20261017:wave1b-tools-20261017-308141f59d306654-16:gate",
    "evidence_hash": "45541c81170897c549c60174d7b60409c4ed2f6670195de1cd807c7d79ca2b19"
  },
  "review": {
    "draft_hash": "4c6a0707df4f673d878ae1d1a0109adf1e34fc6651e0de8628af239a1a7a5f65",
    "reviewer": "publication-gate",
    "reviewed_at": "2026-10-07T00:00:00.000Z",
    "decision": "wave1b-tools-20261017:gate",
    "reason": "2 of 3 judge runs approved with p_yes >= 0.9 (mean 0.92 >= 0.9; 2 needed) and Jev gave 0.66 (>= 0.6 needed)."
  }
}
