path: root/Documentation/git-rev-parse.txt
diff options
authorJunio C Hamano <>2005-12-23 06:35:38 (GMT)
committerJunio C Hamano <>2005-12-23 06:35:38 (GMT)
commit5f94c730f31862c7f500173ee3a9d141c4730f0b (patch)
treee2123685937d061759aa00d483ee46e3aa2dc3ad /Documentation/git-rev-parse.txt
parentc10d63451883f67c37622d2a21b2fc93be2f90c9 (diff)
rev-parse: --show-cdup
When --show-prefix is useful, sometimes it is easier to cd up to the toplevel of the tree. This is equivalent to: git rev-parse --show-prefix | sed -e 's|[^/][^/]*|..|g' but we do not have to invoke sed for that. Signed-off-by: Junio C Hamano <>
Diffstat (limited to 'Documentation/git-rev-parse.txt')
1 files changed, 6 insertions, 1 deletions
diff --git a/Documentation/git-rev-parse.txt b/Documentation/git-rev-parse.txt
index 431b8f6..d638bfc 100644
--- a/Documentation/git-rev-parse.txt
+++ b/Documentation/git-rev-parse.txt
@@ -68,10 +68,15 @@ OPTIONS
Show all refs found in `$GIT_DIR/refs`.
- When the command is invoked from a directory show the
+ When the command is invoked from a subdirectory, show the
path of the current directory relative to the top-level
+ When the command is invoked from a subdirectory, show the
+ path of the top-level directory relative to the current
+ directory (typically a sequence of "../", or an empty string).
--since=datestring, --after=datestring::
Parses the date string, and outputs corresponding
--max-age= parameter for git-rev-list command.