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

Re: [PATCH] allow git to use the PATH for finding subcommands and help docs

From
Scott Parish <srp@srparish.net>
Date
Oct 19, 2007, 14:18 UTC
Message-ID
<20071019141805.GE1463@srparish.net>
In-Reply-To
<4718AF48.9020607@viscovery.net>
On Fri, Oct 19, 2007 at 03:21:12PM +0200, Johannes Sixt wrote:
Show 18 quoted lines
>  Scott Parish schrieb:
> > I have a situation where software for a distribution is installed
> > into a fake "prefix" and then moved to one of several potential
> > places to be used by users. Given that the final location isn't
> > static, i can't depend on builtin_exec_path. I'd really like users
> > to be able to get started with git as easily as possible. With the
> > current setup, they would have to create and maintain either an
> > GIT_EXEC_PATH or an alias for including --exec-path, as well as a
> > MANPATH and PERL5LIB. This seem like an unnessisary burden.
> 
>  Interesting. How does this compare to this 2-patch-series:
> 
>  http://repo.or.cz/w/git/mingw.git?a=commitdiff;h=e479ea2f911b8c70a269ba59372a4fef90f8907c
>  http://repo.or.cz/w/git/mingw.git?a=commitdiff;h=00a4ff4f3f8ec7e6b3ac15456f00b22b03f438ae
> 
>  which I had come up with to accomplish something very similar
>  (on Windows). Your approach looks superior, but I hadn't gone
>  into depths, yet.

I know very little about what's available on windows. Looking at your code, it looks like the command isn't passed in in argv[0] and that it contains the windows style path seperators. My code currently assumes that PATH is a colon separated list, and that directories are separated with '/'. How should these assumptions change for windows?

sRp
-- 
Scott Parish
http://srparish.net/
Previous: Johannes SixtNext: Johannes Sixt
Message 5 of 10 in “allow git to use the PATH for finding subcommands and help docs”
  1. allow git to use the PATH for finding subcommands and help docsScott R Parish, Oct 19, 2007
  2. Johannes SixtOct 19, 2007
  3. allow git to use the PATH for finding subcommands and help docsScott Parish, Oct 19, 2007
  4. Johannes SixtOct 19, 2007
  5. Scott ParishOct 19, 2007
  6. Johannes SixtOct 19, 2007
  7. Johannes SchindelinOct 19, 2007
  8. Mike HommeyOct 19, 2007
  9. Johannes SchindelinOct 19, 2007
  10. Scott ParishOct 20, 2007

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.