summaryrefslogtreecommitdiff
path: root/Documentation/git-rev-parse.txt
diff options
context:
space:
mode:
authorLibravatar Shawn O. Pearce <spearce@spearce.org>2007-01-17 21:08:04 -0500
committerLibravatar Junio C Hamano <junkio@cox.net>2007-01-17 20:45:15 -0800
commitee53aff486d380986e549ea93a5d68e7b7607293 (patch)
tree87c4ecca24de8c703d9aa1dd077a257126a3e098 /Documentation/git-rev-parse.txt
parentDocumentation/git-parse-remote.txt: we deal with config vars as well (diff)
downloadtgif-ee53aff486d380986e549ea93a5d68e7b7607293.tar.xz
Document the master@{n} reflog query syntax.
In ab2a1a32 Junio improved the reflog query logic to support obtaining the n-th prior value of a ref, but this was never documented in git-rev-parse. Now it is. Signed-off-by: Shawn O. Pearce <spearce@spearce.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'Documentation/git-rev-parse.txt')
-rw-r--r--Documentation/git-rev-parse.txt8
1 files changed, 8 insertions, 0 deletions
diff --git a/Documentation/git-rev-parse.txt b/Documentation/git-rev-parse.txt
index 4eaf5a0d1e..aeb37b65d2 100644
--- a/Documentation/git-rev-parse.txt
+++ b/Documentation/git-rev-parse.txt
@@ -152,6 +152,14 @@ blobs contained in a commit.
used immediately following a ref name and the ref must have an
existing log ($GIT_DIR/logs/<ref>).
+* A ref followed by the suffix '@' with an ordinal specification
+ enclosed in a brace pair (e.g. '\{1\}', '\{15\}') to specify
+ the n-th prior value of that ref. For example 'master@\{1\}'
+ is the immediate prior value of 'master' while 'master@\{5\}'
+ is the 5th prior value of 'master'. This suffix may only be used
+ immediately following a ref name and the ref must have an existing
+ log ($GIT_DIR/logs/<ref>).
+
* A suffix '{caret}' to a revision parameter means the first parent of
that commit object. '{caret}<n>' means the <n>th parent (i.e.
'rev{caret}'