From: Scott Parish <sRp@srparish.net>
To: Johannes Schindelin <Johannes.Schindelin@gmx.de>
Cc: git@vger.kernel.org
Subject: Re: [PATCH] "git help -a" should search all exec_paths and PATH
Date: Sun, 21 Oct 2007 17:54:30 -0700 [thread overview]
Message-ID: <20071022005429.GK16291@srparish.net> (raw)
In-Reply-To: <Pine.LNX.4.64.0710212323580.25221@racer.site>
On Sun, Oct 21, 2007 at 11:25:29PM +0100, Johannes Schindelin wrote:
> > To fix this, help.c is modified to search in all the exec_paths and PATH
> > for potential git commands.
>
> With this explanation, I would have expected that you add a loop just like
> in exec-cmd.c. Not anything more. And certainly not the removal of a
> sanity check for the length of the path name.
Well, i took a slightly different approach where that sanity check
wasn't nessisary. Instead of building up a string of the path of
each file, i'm saving the original directory in a file descriptor,
and "cd"ing to the exec_path currently being listed. Because of
that i can just stat() the names returned by readdir. Much simpler
imho
sRp
--
Scott Parish
http://srparish.net/
next prev parent reply other threads:[~2007-10-22 0:54 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-10-21 21:48 [PATCH] "git help -a" should search all exec_paths and PATH Scott R Parish
2007-10-21 22:25 ` Johannes Schindelin
2007-10-22 0:54 ` Scott Parish [this message]
2007-10-22 5:30 ` Shawn O. Pearce
2007-10-22 6:32 ` Scott Parish
2007-10-22 6:39 ` Shawn O. Pearce
2007-10-22 6:06 ` Johannes Sixt
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20071022005429.GK16291@srparish.net \
--to=srp@srparish.net \
--cc=Johannes.Schindelin@gmx.de \
--cc=git@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.