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

Re: "make quick-install-man" broke recently

From
Junio C Hamano <gitster@pobox.com>
Date
Aug 17, 2009, 17:09 UTC
Message-ID
<7vhbw6weo9.fsf@alter.siamese.dyndns.org>
In-Reply-To
<alpine.LFD.2.01.0908170932390.3162@localhost.localdomain>
Linus Torvalds <torvalds@linux-foundation.org> writes:
Show 5 quoted lines
> Grr. Now 'check_path()' is no longer something generically useful.
>
> Could you perhaps instead only change 'checkout_entry()' to do this hack, 
> and leave 'check_path()' as a generic replacement for "lstat()" that 
> doesn't follow symlinks?

Given that non-empty base_dir is only used for "checkout-index --prefix", iow, the "path" internally used by git and fed to our symlink.c cache are supposed to be always relative to the work tree, I think that may be a good thing to do in the short-term.

But only if we won't add any more like "checkout-index --prefix". If you want to implement "git checkout --prefix=over-there/" and if you want to call check_path() directly (iow not as a part of callchain from checkout_entry()) while doing so, for example, you would regret keeping the check_path() function unaware of base_dir, as you would reintroduce the same bug.

I thought about getting rid of base_dir from struct checkout by running create_directories() in checkout-index and chdir(2) there, because this is a very special case codepath anyway. I actually haven't tried it, but it probably will have bad interactions with the way we find $GIT_DIR.

Previous: Linus Torvalds
Message 13 of 13 in “"make quick-install-man" broke recently”
  1. Randal L. SchwartzAug 17, 2009
  2. Junio C HamanoAug 17, 2009
  3. Randal L. SchwartzAug 17, 2009
  4. Junio C HamanoAug 17, 2009
  5. Jacob HelwigAug 17, 2009
  6. Randal L. SchwartzAug 17, 2009
  7. Junio C HamanoAug 17, 2009
  8. Johannes SixtAug 17, 2009
  9. Junio C HamanoAug 17, 2009
  10. Randal L. SchwartzAug 17, 2009
  11. Junio C HamanoAug 17, 2009
  12. Linus TorvaldsAug 17, 2009
  13. Junio C HamanoAug 17, 2009

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.