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

Re: [PATCH v4 1/1] macOS: ls-files path fails if path of workdir is NFD

From
JTJun T <takimoto-j@kba.biglobe.ne.jp>
Date
Jun 4, 2024, 00:56 UTC
Message-ID
<BD63F8A7-986B-424B-B67C-B78887E8CA00@kba.biglobe.ne.jp>
In-Reply-To
<20240531193156.28046-1-tboegi@web.de>
Show 5 quoted lines
> 2024/06/01 4:3, tboegi@web.de <mailto:tboegi@web.de> wrote:
> 
> The solution is to add a call to precompose_string_if_needed()
> to this code in setup.c :
> `work_tree = precompose_string_if_needed(get_git_work_tree());`
This simple patch works for both 'ls-files NFD' and 'ls-files NFC'.
> 
> There is, however, a limitation with this very usage of Git:
> The (repo) local .gitconfig file is not used,

core.precomposeunicode in .git/config is read, in function precompose_argv_prefix(), and NFD in argv is converted to NFC.

But, as you know, the variable the_repository->worktree or the return value of get_git_work_tree() is in NFD.

> 2024/06/03 4:40, Torsten Bögershausen <tboegi@web.de> wrote:
> 
> The root cause may be fixed in a different commit later.

Of course fixing the 'root cause' is better, but I don't know whether it's easy or not.

Anyway, thank you for woking on this problem.

-- Jun

Previous: Torsten Bögershausen
Message 24 of 24 in “strbuf_getcwd() needs precompse_strbuf_if_needed()”
  1. 2/2 strbuf_getcwd() needs precompse_strbuf_if_needed()tboegi@web.de, May 7, 2024
  2. Junio C HamanoMay 7, 2024
  3. Junio C HamanoMay 9, 2024
  4. Torsten BögershausenMay 9, 2024
  5. Junio C HamanoMay 7, 2024
  6. brian m. carlsonMay 8, 2024
  7. 1/2 t0050: ls-files path fails if path of workdir is NFDtboegi@web.de, May 7, 2024
  8. Junio C HamanoMay 7, 2024
  9. 1/1 macOS: ls-files path fails if path of workdir is NFDtboegi@web.de, May 9, 2024
  10. Junio C HamanoMay 9, 2024
  11. Jun. TMay 19, 2024
  12. Torsten BögershausenMay 20, 2024
  13. Junio C HamanoMay 20, 2024
  14. Torsten BögershausenMay 20, 2024
  15. 1/1 macOS: ls-files path fails if path of workdir is NFDtboegi@web.de, May 21, 2024
  16. Junio C HamanoMay 21, 2024
  17. Torsten BögershausenMay 21, 2024
  18. Junio C HamanoMay 21, 2024
  19. Jun. TMay 23, 2024
  20. Torsten BögershausenMay 25, 2024
  21. 1/1 macOS: ls-files path fails if path of workdir is NFDtboegi@web.de, May 31, 2024
  22. Junio C HamanoJun 1, 2024
  23. Torsten BögershausenJun 2, 2024
  24. Jun TJun 4, 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.