@matheusbsbs / matheus-bagliano / commits / babfaba23d
Fork 0

Fix usage of carets in git-rev-parse(1)

... but using a {caret} attribute. Signed-off-by: Jonas Fonseca <fonseca@diku.dk> Signed-off-by: Junio C Hamano <junkio@cox.net>

Jonas Fonseca committed Oct 5, 2005 at 16:56 UTC babfaba23d530e2818db62161825a65e582adbdc
2 files changed +17 -11
Documentation/asciidoc.conf
+5
@@ -7,6 +7,9 @@
7 # Show GIT link as: <command>(<section>); if section is defined, else just show
8 # the command.
9
10 +[attributes]
11 +caret=^
12 +
13 ifdef::backend-docbook[]
14 [gitlink-inlinemacro]
15 {0%{target}}
@@ -19,3 +22,5 @@ ifdef::backend-xhtml11[]
22 [gitlink-inlinemacro]
23 <a href="{target}.html">{target}{0?({0})}</a>
24 endif::backend-xhtml11[]
25 +
26 +
Documentation/git-rev-parse.txt
+12 -11
@@ -54,13 +54,13 @@ OPTIONS
54 `git-diff-\*`).
55
56 --not::
57 - When showing object names, prefix them with '^' and
58 - strip '^' prefix from the object names that already have
57 + When showing object names, prefix them with '{caret}' and
58 + strip '{caret}' prefix from the object names that already have
59 one.
60
61 --symbolic::
62 Usually the object names are output in SHA1 form (with
63 - possible '^' prefix); this option makes them output in a
63 + possible '{caret}' prefix); this option makes them output in a
64 form as close to the original input as possible.
65
66
@@ -93,22 +93,23 @@ what is called an 'extended SHA1' syntax.
93 happen to have both heads/master and tags/master, you can
94 explicitly say 'heads/master' to tell GIT which one you mean.
95
96 -* A suffix '^' to a revision parameter means the first parent of
97 - that commit object. '^<n>' means the <n>th parent (i.e.
98 - 'rev^'
99 - is equivalent to 'rev^1'). As a special rule,
100 - 'rev^0' means the commit itself and is used when 'rev' is the
96 +* A suffix '{caret}' to a revision parameter means the first parent of
97 + that commit object. '{caret}<n>' means the <n>th parent (i.e.
98 + 'rev{caret}'
99 + is equivalent to 'rev{caret}1'). As a special rule,
100 + 'rev{caret}0' means the commit itself and is used when 'rev' is the
101 object name of a tag object that refers to a commit object.
102
103 * A suffix '~<n>' to a revision parameter means the commit
104 object that is the <n>th generation grand-parent of the named
105 commit object, following only the first parent. I.e. rev~3 is
106 - equivalent to rev^^^ which is equivalent to rev^1^1^1.
106 + equivalent to rev{caret}{caret}{caret} which is equivalent to\
107 + rev{caret}1{caret}1{caret}1.
108
108 -'git-rev-parse' also accepts a prefix '^' to revision parameter,
109 +'git-rev-parse' also accepts a prefix '{caret}' to revision parameter,
110 which is passed to 'git-rev-list'. Two revision parameters
111 concatenated with '..' is a short-hand for writing a range
111 -between them. I.e. 'r1..r2' is equivalent to saying '^r1 r2'
112 +between them. I.e. 'r1..r2' is equivalent to saying '{caret}r1 r2'
113
114
115 Author