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

Re: [PATCH] post-update.sample referenced obsolete binary "git-update-server-info"

From
Michael J Gruber <git@drmicha.warpmail.net>
Date
Jul 21, 2009, 08:01 UTC
Message-ID
<4A6575BE.6040308@drmicha.warpmail.net>
In-Reply-To
<87r5wb5s4o.fsf@write-only.cryp.to>
Peter Simons venit, vidit, dixit 20.07.2009 16:46:
Show 18 quoted lines
> Hi Michael,
> 
>  >> -exec git-update-server-info
>  >> +exec git update-server-info
>  >>
>  >
>  > t/t5540-http-push.sh should fail if this really needed a fix (libexec
>  > is in $PATH for hooks).
> 
> you are right, the call to git-update-server-info does succeed, so there
> is no need to make that change.
> 
> Personally, I find it unfortunate, though, that those scripts rely on
> commands that won't exist when a normal user runs them.
> 
> Just my 2 cents,
> Peter
> 
Anyone can run them, just not from the default $PATH.

In fact, calling the dashed versions from the hooks is both safer and (marginally) more efficient: Many people have several versions of git lying around, and we've had more than one "bug" report where people messed up because of mixing git bits from several versions. Calling the dashed form above relies on the environment as set up by the caller, not the user (who may have several "git" in $PATH, but not "git-update-server-info"). Also, the command is called directly rather than indirectly with "git" having to look for it.

Michael
Previous: Peter SimonsNext: Peter Simons
Message 4 of 5 in “post-update.sample referenced obsolete binary "git-update-server-info"”
  1. post-update.sample referenced obsolete binary "git-update-server-info"Peter Simons, Jul 17, 2009
  2. Michael J GruberJul 17, 2009
  3. Peter SimonsJul 20, 2009
  4. Michael J GruberJul 21, 2009
  5. Peter SimonsJul 21, 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.