Re: [RFC/PATCH] Documentation: Don't assume git-sh-setup and git-parse-remote are in the PATH
- From
jrnieder@uchicago.edu <jrnieder@uchicago.edu>
- Date
- Jun 29, 2008, 16:10 UTC
- Message-ID
- <Pine.GSO.4.62.0806291026310.8371@harper.uchicago.edu>
- In-Reply-To
- <20080629053823.GA8262@sigill.intra.peff.net>
On Sun, 29 Jun 2008, Jeff King wrote:
Show 12 quoted lines
> I think the right question is: > > PATH=$PATH:$(git --exec-path) > . git-sh-setup > > or > > . "$(git --exec-path)/git-sh-setup" > > ? > > Generally, I would prefer the latter because it has no side effects.
On Sun, 28 Jun 2008, Alex Riesen wrote:
> . "$(git --exec-path)/git-sh-setup"
I agree. I was blindly following the instructions from the release notes to Git 1.5.4. After thinking about it a little and reading git-sh-setup.sh and git-parse-remote.sh, it does seem safe not to add the exec-path to PATH.
How about this documentation patch? (This time tested! With hg-fast-export
appropriately modified:
$ hg clone http://hg.sharesource.org/asciidoc
$ mkdir asciidoc-git && cd asciidoc-git
$ git init && hg-fast-export.sh -r /path/to/asciidoc --quiet
$ git checkout
$ sudo ./install.sh
$ cd /path/to/git/Documentation && make git-{sh-setup,parse-remote}.html
I haven't tried rebuilding manpages, though.)Junio: I stole the commit message from you. I hope you don't mind.
-- %< --
Subject: [PATCH] Documentation: don't assume git-sh-setup and git-parse-remote are in PATH
When git-parse-remote and git-sh-setup are not installed in $(bindir) anymore, the shell script library won't be found on user's $PATH in general.
Signed-off-by: Jonathan Nieder <jrnieder@uchicago.edu> --- Documentation/git-parse-remote.txt | 2 +- Documentation/git-sh-setup.txt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/Documentation/git-parse-remote.txt b/Documentation/git-parse-remote.txt index 951dbd6..421312e 100644 --- a/Documentation/git-parse-remote.txt +++ b/Documentation/git-parse-remote.txt @@ -8,7 +8,7 @@ git-parse-remote - Routines to help parsing remote repository access parameters SYNOPSIS -------- -'. git-parse-remote' +'. "$(git --exec-path)/git-parse-remote"' DESCRIPTION ----------- diff --git a/Documentation/git-sh-setup.txt b/Documentation/git-sh-setup.txt index c543170..6731f9a 100644 --- a/Documentation/git-sh-setup.txt +++ b/Documentation/git-sh-setup.txt @@ -7,7 +7,7 @@ git-sh-setup - Common git shell script setup code SYNOPSIS -------- -'git-sh-setup' +'. "$(git --exec-path)/git-sh-setup"' DESCRIPTION -----------
-- 1.5.5.1.328.gbfcc6