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

Re: [PATCH] diff: run arguments through precompose_argv

From
Torsten Bögershausen <tboegi@web.de>
Date
Apr 6, 2016, 07:47 UTC
Message-ID
<5704BF14.9060100@web.de>
In-Reply-To
<C52E38F0-B0F2-4769-A2C7-798D0CD99B47@fournova.com>
On 06.04.16 08:51, Alexander Rinass wrote:
Show 31 quoted lines
> 
>> On 05 Apr 2016, at 21:15, Johannes Sixt <j6t@kdbg.org> wrote:
>>
>> Am 05.04.2016 um 19:09 schrieb Junio C Hamano:
>>>> Thanks-to: Torsten Bögershausen <tboegi@web.de>
>>
>> I sense NFD disease: The combining diaresis should combine with the o, not the g. Here is a correct line to copy-and-paste if you like:
>>
>> Thanks-to: Torsten Bögershausen <tboegi@web.de>
>>
>> -- Hannes
> 
> Thanks for reviewing and catching the NFD encoding error.
> 
> I will send in a patch v2 with the correct NFC encoding.
> 
> Would you also like me to alter the commit message as mentioned by Junio?
> 
> I could rewrite the sentence:
> 
> “As a result, no diff is displayed when feeding such a file path to the
> diff command.”
> 
> into simply saying:
> 
> “As a result, no diff is displayed.”
> 
> However, I don't read the original message as it would imply that only
> file paths are affected by the precompose_argv call. 
> 
> Are there other suggestions on improving the commit message?
May be something like this, (but this is highly a personal taste question)

When running diff commands, file paths containing decomposed unicode code points are not converted to precomposed unicode form under Mac OS X.

As a result, no diff is displayed.

Opposite to most builtin commands, the diff builtin is missing the parse_options call, which internally runs arguments through the precompose_argv call, which ensures all arguments are in precomposed unicode form.

Fix the problem by adding a precompose_argv call to diff, diff-index, diff-files and diff-tree.
Signed-off-by: Alexander Rinass <alex@fournova.com>
Helped-By: Torsten Bögershausen <tboegi@web.de>
Helped-By: Junio C Hamano <gitster@pobox.com>
Previous: Alexander RinassNext: Junio C Hamano
Message 8 of 12 in “diff: run arguments through precompose_argv”
  1. diff: run arguments through precompose_argvAlexander Rinass, Apr 4, 2016
  2. diff: run arguments through precompose_argvAlexander Rinass, Apr 4, 2016
  3. Junio C HamanoApr 5, 2016
  4. Johannes SixtApr 5, 2016
  5. Torsten BögershausenApr 5, 2016
  6. Junio C HamanoApr 5, 2016
  7. Alexander RinassApr 6, 2016
  8. Torsten BögershausenApr 6, 2016
  9. Junio C HamanoApr 6, 2016
  10. Junio C HamanoMay 11, 2016
  11. Alexander RinassMay 12, 2016
  12. Junio C HamanoMay 12, 2016

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.