]> git.ipfire.org Git - thirdparty/git.git/blame - Documentation/git-rev-list.txt
Documentation: be consistent about "git-" versus "git "
[thirdparty/git.git] / Documentation / git-rev-list.txt
CommitLineData
2cf565c5
DG
1git-rev-list(1)
2===============
2cf565c5
DG
3
4NAME
5----
6git-rev-list - Lists commit objects in reverse chronological order
7
8
9SYNOPSIS
10--------
353ce815 11[verse]
69e0c256 12'git-rev-list' [ \--max-count=number ]
d5db6c9e 13 [ \--skip=number ]
353ce815
JF
14 [ \--max-age=timestamp ]
15 [ \--min-age=timestamp ]
16 [ \--sparse ]
17 [ \--no-merges ]
25db465a 18 [ \--first-parent ]
93b74bca 19 [ \--remove-empty ]
29a6c3f8 20 [ \--full-history ]
0d2c9d67 21 [ \--not ]
353ce815 22 [ \--all ]
a5aa930d
UKK
23 [ \--branches ]
24 [ \--tags ]
25 [ \--remotes ]
42cabc34 26 [ \--stdin ]
27350891 27 [ \--quiet ]
765ac8ec 28 [ \--topo-order ]
353ce815 29 [ \--parents ]
e3c1500f 30 [ \--timestamp ]
b24bace5 31 [ \--left-right ]
55a643ed 32 [ \--cherry-pick ]
7cbcf4d5 33 [ \--encoding[=<encoding>] ]
bd95fcd3 34 [ \--(author|committer|grep)=<pattern> ]
e5633cbb
JH
35 [ \--regexp-ignore-case | \-i ]
36 [ \--extended-regexp | \-E ]
dc1c0fff 37 [ \--fixed-strings | \-F ]
1701872f 38 [ \--date={local|relative|default|iso|rfc|short} ]
ec579767 39 [ [\--objects | \--objects-edge] [ \--unpacked ] ]
353ce815
JF
40 [ \--pretty | \--header ]
41 [ \--bisect ]
457f08a0 42 [ \--bisect-vars ]
3ac9f612 43 [ \--bisect-all ]
d249b455 44 [ \--merge ]
9c5e66e9 45 [ \--reverse ]
4d12a471 46 [ \--walk-reflogs ]
8e64006e 47 [ \--no-walk ] [ \--do-walk ]
353ce815 48 <commit>... [ \-- <paths>... ]
2cf565c5
DG
49
50DESCRIPTION
51-----------
8c02eee2 52
2cf565c5 53Lists commit objects in reverse chronological order starting at the
adcd3512 54given commit(s), taking ancestry relationship into account. This is
2cf565c5
DG
55useful to produce human-readable log output.
56
8c02eee2
JF
57Commits which are stated with a preceding '{caret}' cause listing to
58stop at that point. Their parents are implied. Thus the following
59command:
60
61-----------------------------------------------------------------------
b1889c36 62 $ git rev-list foo bar ^baz
8c02eee2
JF
63-----------------------------------------------------------------------
64
adcd3512
MU
65means "list all the commits which are included in 'foo' and 'bar', but
66not in 'baz'".
67
8c02eee2
JF
68A special notation "'<commit1>'..'<commit2>'" can be used as a
69short-hand for "{caret}'<commit1>' '<commit2>'". For example, either of
70the following may be used interchangeably:
69e0c256 71
8c02eee2 72-----------------------------------------------------------------------
b1889c36
JN
73 $ git rev-list origin..HEAD
74 $ git rev-list HEAD ^origin
8c02eee2
JF
75-----------------------------------------------------------------------
76
77Another special notation is "'<commit1>'...'<commit2>'" which is useful
78for merges. The resulting set of commits is the symmetric difference
0d2c9d67
RS
79between the two operands. The following two commands are equivalent:
80
8c02eee2 81-----------------------------------------------------------------------
b1889c36
JN
82 $ git rev-list A B --not $(git merge-base --all A B)
83 $ git rev-list A...B
8c02eee2
JF
84-----------------------------------------------------------------------
85
5162e697 86linkgit:git-rev-list[1] is a very essential git program, since it
8c02eee2
JF
87provides the ability to build and traverse commit ancestry graphs. For
88this reason, it has a lot of different options that enables it to be
5162e697
DM
89used by commands as different as linkgit:git-bisect[1] and
90linkgit:git-repack[1].
69e0c256 91
df8baa42
JF
92OPTIONS
93-------
8c02eee2 94
fdcf39e5
MV
95:git-rev-list: 1
96include::rev-list-options.txt[]
331b51d2
JN
97
98include::pretty-formats.txt[]
99
100
2cf565c5
DG
101Author
102------
103Written by Linus Torvalds <torvalds@osdl.org>
104
105Documentation
106--------------
8c02eee2
JF
107Documentation by David Greaves, Junio C Hamano, Jonas Fonseca
108and the git-list <git@vger.kernel.org>.
2cf565c5
DG
109
110GIT
111---
9e1f0a85 112Part of the linkgit:git[1] suite