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

Re: [BUG] Colon in remote urls

From
Junio C Hamano <gitster@pobox.com>
Date
Dec 9, 2016, 19:07 UTC
Message-ID
<xmqqwpf8rkeq.fsf@gitster.mtv.corp.google.com>
In-Reply-To
<20161209152219.ehfk475vdg4levop@sigill.intra.peff.net>
Jeff King <peff@peff.net> writes:
> (One other option is to just declare that the quarantine feature doesn't
> work with colons in the pathname, but stop turning it on by default. I'm
> not sure I like that, though).

I think we long time ago in 2005 have declared that a colon in a directory name would not work for Git repositories because of things like GIT_CEILING_DIRECTORIES, GIT_ALTERNATE_OBJECT_DIRECTORIES; so I do not think we terribly mind that direction.

> Here's a rough idea of what the quoting solution could look like. It
> should make your case work, but I'm not sure what we want to do about
> backwards-compatibility, if anything.

Yes, obviously it robs from those with backslash in their pathnames to please those with colons; we've never catered to the latter, so I am not sure if the trade-off is worth it.

I can see how adding a new environment variable could work, though. A naive way would be to add GIT_ALT_OBJ_DIRS that uses your quoting when splitting its elements, give it precedence over the existing one (or allow to use both and take union as the set of alternate object stores) and make sure that the codepaths we use internally uses the new variable. But if the quarantine codepath will stay to be the only user of this mechanism (and I strongly suspect that will be the case), the new environment could just be pointing at a single directory, i.e. GIT_OBJECT_QUARANTINE_DIRECTORY, whose value is added without splitting to the list of alternate object stores, and the quarantine codepath can export that instead.

Previous: Jeff KingNext: Jeff King
Message 3 of 46 in “[BUG] Colon in remote urls”
  1. Klaus EthgenDec 9, 2016
  2. Jeff KingDec 9, 2016
  3. Junio C HamanoDec 9, 2016
  4. Jeff KingDec 10, 2016
  5. 0/2 handling alternates paths with colonsJeff King, Dec 12, 2016
  6. 1/2 alternates: accept double-quoted pathsJeff King, Dec 12, 2016
  7. Duy NguyenDec 13, 2016
  8. Jeff KingDec 13, 2016
  9. Junio C HamanoDec 13, 2016
  10. Duy NguyenDec 17, 2016
  11. 2/2 tmp-objdir: quote paths we add to alternatesJeff King, Dec 12, 2016
  12. Johannes SixtDec 12, 2016
  13. Jeff KingDec 13, 2016
  14. Junio C HamanoDec 13, 2016
  15. Jeff KingDec 13, 2016
  16. Junio C HamanoDec 13, 2016
  17. 3/2 t5547-push-quarantine: run the path separator test on Windows, tooJohannes Sixt, Dec 13, 2016
  18. Jeff KingDec 13, 2016
  19. Junio C HamanoDec 13, 2016
  20. 4/2 t5615-alternate-env: double-quotes in file names do not work on WindowsJohannes Sixt, Dec 21, 2016
  21. Jeff KingDec 21, 2016
  22. Johannes SixtDec 22, 2016
  23. Johannes SixtDec 22, 2016
  24. Johannes SchindelinDec 22, 2016
  25. Jeff KingDec 22, 2016
  26. Junio C HamanoDec 12, 2016
  27. Jeff KingDec 13, 2016
  28. Junio C HamanoDec 13, 2016
  29. Jeff KingDec 13, 2016
  30. Junio C HamanoDec 13, 2016
  31. Jeff KingDec 13, 2016
  32. Klaus EthgenDec 10, 2016
  33. Jeff KingDec 10, 2016
  34. Klaus EthgenDec 10, 2016
  35. Johannes SixtDec 9, 2016
  36. Jeff KingDec 10, 2016
  37. Klaus EthgenDec 10, 2016
  38. Jeff KingDec 10, 2016
  39. Klaus EthgenDec 10, 2016
  40. Klaus EthgenDec 10, 2016
  41. Johannes SchindelinDec 10, 2016
  42. Klaus EthgenDec 11, 2016
  43. Philip OakleyDec 11, 2016
  44. Johannes SchindelinDec 12, 2016
  45. Klaus EthgenDec 12, 2016
  46. Johannes SchindelinDec 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.