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

Re: [PATCH v2 2/2] merge/pull: extend merge.stat configuration variable to cover --compact-summary

From
KHKristoffer Haugsbakk <kristofferhaugsbakk@fastmail.com>
Date
Jun 13, 2025, 12:09 UTC
Message-ID
<deb4951a-5d1b-416d-bcad-5d675d8155cc@app.fastmail.com>
In-Reply-To
<20250612222537.2426059-3-gitster@pobox.com>
On Fri, Jun 13, 2025, at 00:25, Junio C Hamano wrote:
> Extend it to be "Boolean or text", that takes false, true, or
> "compact", with the last one triggering the --compact-summary
> option introduced earlier.

Would it make sense to make `diffstat` an alias for `true`? I’m not sure since you need to keep `true` anyway so you still have that historical artifact (?)[1] of `true` meaning `diffstat`.

† 1: In the sense of what was added first
Also
> "compact", with the last one triggering the --compact-summary
> option introduced earlier.

So `merge.stat` can be used instead of `--compact-summary`. But now the option does not mention `merge.stat`?

Show 10 quoted lines
>  `merge.stat`::
> -	Whether to print the diffstat between `ORIG_HEAD` and the merge result
> -	at the end of the merge.  True by default.
> +	What, if anything, to print between `ORIG_HEAD` and the merge result
> +	at the end of the merge.  Possible values are:
> ++
> +--
> +`false`;; Show nothing.
> +`true`;; Show `git diff --diffstat ORIG_HEAD`.
> +`compact`;; Show `git diff --compact-summary ORIG_HEAD`.

I can’t run `git diff --diffstat ORIG_HEAD`. `--diffstat` is not an option.

> +If this variable is left unspecified, it defaults to `true`.
I think this is simpler:
    Defaults to `true`.

There’s also several places in this doc which uses something similar judging by a search for “defaults to”. Only exception is `merge.renameLimit`:

    If not specified, defaults to
Previous: Junio C HamanoNext: Junio C Hamano
Message 6 of 7 in “git pull/merge --compact-summary”
  1. 0/2 git pull/merge --compact-summaryJunio C Hamano, Jun 12, 2025
  2. 1/2 merge/pull: --compact-summaryJunio C Hamano, Jun 12, 2025
  3. Kristoffer HaugsbakkJun 13, 2025
  4. Junio C HamanoJun 13, 2025
  5. 2/2 merge/pull: extend merge.stat configuration variable to cover --compact-summaryJunio C Hamano, Jun 12, 2025
  6. Kristoffer HaugsbakkJun 13, 2025
  7. Junio C HamanoJun 13, 2025

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.