Re: [RFC/PATCH] git wrapper: add --git-path=<path> and --bare options
- From
Linus Torvalds <torvalds@osdl.org>
- Date
- Jul 25, 2006, 17:43 UTC
- Message-ID
- <Pine.LNX.4.64.0607251042120.29649@g5.osdl.org>
- In-Reply-To
- <Pine.LNX.4.63.0607251926190.29667@wbgn013.biozentrum.uni-wuerzburg.de>
On Tue, 25 Jul 2006, Johannes Schindelin wrote:
Show 6 quoted lines
> > SYNOPSIS > -------- > -'git' [--version] [--exec-path[=GIT_EXEC_PATH]] [--help] COMMAND [ARGS] > +'git' [--version] [--exec-path[=GIT_EXEC_PATH]] [-p|--paginate] > + [--bare] [--git-dir=GIT_DIR] [--help] COMMAND [ARGS]
Here you have "--git-dir"
Show 10 quoted lines
> @@ -41,6 +42,15 @@ OPTIONS > environment variable. If no path is given 'git' will print > the current setting and then exit. > > +-p|--paginate:: > + Pipe all output into 'less' (or if set, $PAGER). > + > +--git-path=<path>:: > + Set the path to the repository. This can also be controlled by > + setting the GIT_DIR environment variable.
But here you have "--git-path".
Show 6 quoted lines
> + } else if (!strcmp(cmd, "--git-dir") && *argc > 1) {
> + setenv("GIT_DIR", (*argv)[1], 1);
> + (*argv)++;
> + (*argc)--;
> + } else if (!strncmp(cmd, "--git-dir=", 10)) {
> + setenv("GIT_DIR", cmd + 10, 1);And here you have "--git-dir" again.
Since "--git-dir" makes more sense than "--git-path", I'd suggest just fixing the OPTIONS section ;)
Linus