git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* intended use of "git --exec-path"?
@ 2007-10-24  4:32 Scott Parish
  2007-10-24  4:38 ` Shawn O. Pearce
  2007-10-24  8:08 ` Andreas Ericsson
  0 siblings, 2 replies; 5+ messages in thread
From: Scott Parish @ 2007-10-24  4:32 UTC (permalink / raw)
  To: git

"git --exec-path" presently prints out the highest priority path
to find executable in. That's a what; i'm curious why and when it
should be used. Basically i'm wondering if its still useful, and
what, if anything, it should be printing.

Thanks
sRp

-- 
Scott Parish
http://srparish.net/

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: intended use of "git --exec-path"?
  2007-10-24  4:32 intended use of "git --exec-path"? Scott Parish
@ 2007-10-24  4:38 ` Shawn O. Pearce
  2007-10-24  5:47   ` Scott Parish
  2007-10-24  8:08 ` Andreas Ericsson
  1 sibling, 1 reply; 5+ messages in thread
From: Shawn O. Pearce @ 2007-10-24  4:38 UTC (permalink / raw)
  To: Scott Parish; +Cc: git

Scott Parish <sRp@srparish.net> wrote:
> "git --exec-path" presently prints out the highest priority path
> to find executable in. That's a what; i'm curious why and when it
> should be used. Basically i'm wondering if its still useful, and
> what, if anything, it should be printing.

git-gui uses it.  git-gui runs git-* by prefixing it with the
exec path.  It also scans the first line of the file if we are on
Windows and the "executable" doesn't end in ".exe" so it can figure
out what process to run it through.

So it really can't go away.

-- 
Shawn.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: intended use of "git --exec-path"?
  2007-10-24  4:38 ` Shawn O. Pearce
@ 2007-10-24  5:47   ` Scott Parish
  2007-10-24  5:54     ` David Symonds
  0 siblings, 1 reply; 5+ messages in thread
From: Scott Parish @ 2007-10-24  5:47 UTC (permalink / raw)
  To: Shawn O. Pearce; +Cc: git

On Wed, Oct 24, 2007 at 12:38:19AM -0400, Shawn O. Pearce wrote:

> Scott Parish <sRp@srparish.net> wrote:
> > "git --exec-path" presently prints out the highest priority path
> > to find executable in. That's a what; i'm curious why and when it
> > should be used. Basically i'm wondering if its still useful, and
> > what, if anything, it should be printing.
> 
> git-gui uses it.  git-gui runs git-* by prefixing it with the
> exec path.  It also scans the first line of the file if we are on
> Windows and the "executable" doesn't end in ".exe" so it can figure
> out what process to run it through.
> 
> So it really can't go away.

So it sounds like it might be more helpful for git to return its
PATH, so other programs can set their PATH or search for executables
accordingly.

sRp

-- 
Scott Parish
http://srparish.net/

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: intended use of "git --exec-path"?
  2007-10-24  5:47   ` Scott Parish
@ 2007-10-24  5:54     ` David Symonds
  0 siblings, 0 replies; 5+ messages in thread
From: David Symonds @ 2007-10-24  5:54 UTC (permalink / raw)
  To: Scott Parish; +Cc: Shawn O. Pearce, git

On 10/24/07, Scott Parish <sRp@srparish.net> wrote:
> On Wed, Oct 24, 2007 at 12:38:19AM -0400, Shawn O. Pearce wrote:
>
> > Scott Parish <sRp@srparish.net> wrote:
> > > "git --exec-path" presently prints out the highest priority path
> > > to find executable in. That's a what; i'm curious why and when it
> > > should be used. Basically i'm wondering if its still useful, and
> > > what, if anything, it should be printing.
> >
> > git-gui uses it.  git-gui runs git-* by prefixing it with the
> > exec path.  It also scans the first line of the file if we are on
> > Windows and the "executable" doesn't end in ".exe" so it can figure
> > out what process to run it through.
> >
> > So it really can't go away.
>
> So it sounds like it might be more helpful for git to return its
> PATH, so other programs can set their PATH or search for executables
> accordingly.

You don't necessarily want to be monkeying around with $PATH if you're
trying to use a particular git installation (say, a build of next)
instead of your "proper" install, which is in your $PATH; if you call
/some/random/path/git-whatever, it should use the git tools in
/some/random/path/, not in $PATH.


Dave.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: intended use of "git --exec-path"?
  2007-10-24  4:32 intended use of "git --exec-path"? Scott Parish
  2007-10-24  4:38 ` Shawn O. Pearce
@ 2007-10-24  8:08 ` Andreas Ericsson
  1 sibling, 0 replies; 5+ messages in thread
From: Andreas Ericsson @ 2007-10-24  8:08 UTC (permalink / raw)
  To: Scott Parish; +Cc: git

Scott Parish wrote:
> "git --exec-path" presently prints out the highest priority path
> to find executable in. That's a what; i'm curious why and when it
> should be used. Basically i'm wondering if its still useful, and
> what, if anything, it should be printing.
> 

git supports having all its "helpers" in a separate path. Since
there were performance concerns with having scripts call the git
wrapper for every invocation of every git program, the --exec-path
option was added when the wrapper was rewritten in C.

Unless it's a very tight loop that runs non-builtin programs,
there's really no reason for scripts to use the git-whatever form
of commands, but the ability to do so should probably be retained
more or less forever. See 8e49d50388211a0f3e7286f6ee600bf7736f4814
for details.

-- 
Andreas Ericsson                   andreas.ericsson@op5.se
OP5 AB                             www.op5.se
Tel: +46 8-230225                  Fax: +46 8-230231

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2007-10-24  8:08 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-10-24  4:32 intended use of "git --exec-path"? Scott Parish
2007-10-24  4:38 ` Shawn O. Pearce
2007-10-24  5:47   ` Scott Parish
2007-10-24  5:54     ` David Symonds
2007-10-24  8:08 ` Andreas Ericsson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).