From: Junio C Hamano Date: Wed, 23 May 2012 20:35:19 +0000 (-0700) Subject: Merge branch 'js/rev-parse-doc-fix' X-Git-Tag: v1.7.11-rc0~16 X-Git-Url: https://git.lorimer.id.au/gitweb.git/diff_plain/8d19426f985afdf4cc34f88198226964566dcdc1?hp=-c Merge branch 'js/rev-parse-doc-fix' By Jon Seymour * js/rev-parse-doc-fix: rev-parse doc: --git-dir does not always show a relative path --- 8d19426f985afdf4cc34f88198226964566dcdc1 diff --combined Documentation/git-rev-parse.txt index f63b81aad6,00e73c84c7..4cc3e9586f --- a/Documentation/git-rev-parse.txt +++ b/Documentation/git-rev-parse.txt @@@ -8,7 -8,6 +8,7 @@@ git-rev-parse - Pick out and massage pa SYNOPSIS -------- +[verse] 'git rev-parse' [ --option ] ... DESCRIPTION @@@ -113,14 -112,15 +113,14 @@@ OPTION + If a `pattern` is given, only refs matching the given shell glob are shown. If the pattern does not contain a globbing character (`?`, -`{asterisk}`, or `[`), it is turned into a prefix match by -appending `/{asterisk}`. +`*`, or `[`), it is turned into a prefix match by appending `/*`. --glob=pattern:: Show all refs matching the shell glob pattern `pattern`. If the pattern does not start with `refs/`, this is automatically prepended. If the pattern does not contain a globbing - character (`?`, `{asterisk}`, or `[`), it is turned into a prefix - match by appending `/{asterisk}`. + character (`?`, `*`, or `[`), it is turned into a prefix + match by appending `/*`. --show-toplevel:: Show the absolute path of the top-level directory. @@@ -137,7 -137,8 +137,8 @@@ --git-dir:: Show `$GIT_DIR` if defined. Otherwise show the path to - the .git directory, relative to the current directory. + the .git directory. The path shown, when relative, is + relative to the current working directory. + If `$GIT_DIR` is not defined and the current directory is not detected to lie in a git repository or work tree @@@ -179,10 -180,6 +180,10 @@@ print a message to stderr and exit wit ...:: Flags and parameters to be parsed. +--resolve-git-dir :: + Check if is a valid git-dir or a git-file pointing to a valid + git-dir. If is a valid git-dir the resolved path to git-dir will + be printed. include::revisions.txt[] @@@ -312,6 -309,16 +313,6 @@@ $ git rev-parse --default master --veri + but if $REV is empty, the commit object name from master will be printed. - -Author ------- -Written by Linus Torvalds . -Junio C Hamano and Pierre Habouzit - -Documentation --------------- -Documentation by Junio C Hamano and the git-list . - GIT --- Part of the linkgit:git[1] suite