git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH 0/2] diff- family --stat width

From
Thomas Koutcher via GitGitGadget <gitgitgadget@gmail.com>
Date
Apr 21, 2022, 20:15 UTC
Message-ID
<pull.1256.git.git.1650572159.gitgitgadget@gmail.com>

diff- family commands do not use the full terminal width. This is visible in Tig which uses git diff-files to show diffs for unstaged changes. When trying to display diffs with long filenames, the diffstat does not improve when the Tig window size is increased.

This patch makes diff-files, diff-index and diff-tree --stat behave like diff --stat and use the full terminal width. The handling of the config option diff.statGraphWidth is also added.

Thomas Koutcher (2):
  diff- family --stat: use the full terminal width
  diff- family --stat: honour config option to limit graph width
 builtin/diff-files.c | 2 ++
 builtin/diff-index.c | 2 ++
 builtin/diff-tree.c  | 2 ++
 diff.c               | 9 +++++----
 4 files changed, 11 insertions(+), 4 deletions(-)
base-commit: 6cd33dceed60949e2dbc32e3f0f5e67c4c882e1e
Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-git-1256%2Fkoutcher%2Fdiff-family-stat-width-v1
Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-git-1256/koutcher/diff-family-stat-width-v1
Pull-Request: https://github.com/git/git/pull/1256
-- 
gitgitgadget
Next: Thomas Koutcher via GitGitGadget
Message 1 of 5 in “diff- family --stat width”
  1. 0/2 diff- family --stat widthThomas Koutcher via GitGitGadget, Apr 21, 2022
  2. 1/2 diff- family --stat: use the full terminal widthThomas Koutcher via GitGitGadget, Apr 21, 2022
  3. 2/2 diff- family --stat: honour config option to limit graph widthThomas Koutcher via GitGitGadget, Apr 21, 2022
  4. Junio C HamanoApr 21, 2022
  5. Thomas KoutcherApr 29, 2022

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.