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

Re: [PATCH 0/2] Support diff.wordDiff config

From
Kristoffer Haugsbakk <code@khaugsbakk.name>
Date
Mar 2, 2024, 19:57 UTC
Message-ID
<34bb249d-4a4d-4cc7-b737-bb18398341d0@app.fastmail.com>
In-Reply-To
<CAOLa=ZR6tN8eQhByaUobj3kS9wwYegsOQNT8cjZYA-YATJJt7w@mail.gmail.com>
Hi
On Sat, Mar 2, 2024, at 19:02, Karthik Nayak wrote:
Show 16 quoted lines
> On Sat, Mar 2, 2024 at 6:03 PM Junio C Hamano <gitster@pobox.com> wrote:
>>
>> Karthik Nayak <karthik.188@gmail.com> writes:
>>
>> > This patch series adds the diff.wordDiff config option. This mimics the
>> > '--word-diff' option of `git-diff(1)`.
>>
>> Is it even be sensible to introduce this configuration variable in
>> the first place?  What would this do to users who set this variable
>> and use third-party or their own scripts that run "git diff" under
>> the hood?
>
> This is definitely a good question to ask. I'm primarily not a user of this
> option, and this patch series was more of to start this discussion, based
> on the request. I'm comfortable dropping the patch series too if it doesn't
> make much sense.
This looks similar to the discussion from a [stash] topic:
• Proposed introducing config variables which change how `git stash
  push` and `git stash save` behave (what they save)
• Concern about how that could break third-party scripts

Like here it would be opt-in. But the user might have no idea what kind of scripts/programs that they use that happen to use git-stash(1).

(That’s at least how I read the thread)

I guess the concern might be worse for git-stash(1) since it seems very natural to use that command in scripts in order to deal with a working tree that might be in a who-knows condition: just get these things out of the way so I can do what I want.

🔗 [stash]: https://lore.kernel.org/git/xmqq34tnyhhf.fsf@gitster.g/
-- 
Kristoffer Haugsbakk
Previous: Karthik NayakNext: Chris Torek
Message 10 of 17 in “Allow setting diff.worddiff=color via gitconfig”
  1. Olliver SchinaglFeb 28, 2024
  2. 0/2 Support diff.wordDiff configKarthik Nayak, Mar 2, 2024
  3. 1/2 t4034: extract out `diff_with_opts`Karthik Nayak, Mar 2, 2024
  4. 2/2 diff: add 'diff.wordDiff' config optionKarthik Nayak, Mar 2, 2024
  5. Eric SunshineMar 2, 2024
  6. Karthik NayakMar 2, 2024
  7. Jean-Noël AVILAMar 2, 2024
  8. Junio C HamanoMar 2, 2024
  9. Karthik NayakMar 2, 2024
  10. Kristoffer HaugsbakkMar 2, 2024
  11. Chris TorekMar 3, 2024
  12. Junio C HamanoMar 3, 2024
  13. Olliver SchinaglMar 22, 2024
  14. Dragan SimicMar 25, 2024
  15. Olliver SchinaglMar 22, 2024
  16. Olliver SchinaglMar 22, 2024
  17. Olliver SchinaglMar 22, 2024

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.