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

Re: [PATCH] t1410: fix breakage on case-insensitive filesystems

From
Junio C Hamano <gitster@pobox.com>
Date
Nov 10, 2014, 02:56 UTC
Message-ID
<CAPc5daUJBs-GwEkJPwru6wjb6pJOMSceEAznXQ+ZW-mOyr-ipw@mail.gmail.com>
In-Reply-To
<20141109015918.GA24736@peff.net>
On Sat, Nov 8, 2014 at 5:59 PM, Jeff King <peff@peff.net> wrote:
Show 7 quoted lines
>
> Two tests recently added to t1410 create branches "a" and
> "a/b" to test d/f conflicts on reflogs. Earlier, unrelated
> tests in that script create the path "A/B" in the working
> tree.  There's no conflict on a case-sensitive filesystem,
> but on a case-insensitive one, "git log" will complain that
> "a/b" is both a revision and a working tree path.
Thanks for a clear problem description.
> We could fix this by using a "--" to disambiguate, but we
> are probably better off using names that are less confusing
> to make it more clear that they are unrelated to the working
> tree files.  This patch turns "a/b" into "one/two".

Hmph, but the branch a and the file A _do_ have names that are unrelated to each other, and it is only the case insensitive fs that is confused ;-). Renaming is not so bad and certainly is not wrong per-se as a workaround, but I have this suspicion that it sends a wrong message to people on such a filesystem, namely, "you cannot use Git to manage a file called 'master'", or something silly like that. Disambiguation with double-dashes does not have such a problem, and instead shows a way how scripts that are meant to be portable is written. More importantly, that is more in line with the problem description (i.e. we complain pointing out the ambiguity, implying that everything is fine as long as you disambiguate).

So I would rather see the workaround done that way.

But that is only if this were before you actually wrote the patch. The above is not a preference strong enough to make me ask you to reroll ;-)

Thanks.
Previous: Michael BlumeNext: Jeff King
Message 13 of 26 in “Test failure”
  1. Michael BlumeNov 8, 2014
  2. Jeff KingNov 9, 2014
  3. t1410: fix breakage on case-insensitive filesystemsJeff King, Nov 9, 2014
  4. Michael BlumeNov 9, 2014
  5. Junio C HamanoNov 9, 2014
  6. Jeff KingNov 10, 2014
  7. Junio C HamanoNov 10, 2014
  8. Jeff KingNov 10, 2014
  9. Torsten BögershausenNov 9, 2014
  10. Michael BlumeNov 9, 2014
  11. Torsten BögershausenNov 9, 2014
  12. Michael BlumeNov 10, 2014
  13. Junio C HamanoNov 10, 2014
  14. Jeff KingNov 10, 2014
  15. Johannes SixtNov 12, 2014
  16. Jeff KingNov 12, 2014
  17. Johannes SixtNov 13, 2014
  18. Jeff KingNov 13, 2014
  19. Junio C HamanoNov 13, 2014
  20. Johannes SixtNov 14, 2014
  21. Jeff KingNov 14, 2014
  22. Junio C HamanoNov 14, 2014
  23. Andreas SchwabNov 14, 2014
  24. Johannes SixtNov 15, 2014
  25. Windows: correct detection of EISDIR in mingw_open()Johannes Sixt, Nov 16, 2014
  26. Michael BlumeNov 9, 2014

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.