Documentation / git-rev-list.txton commit merge-recursive --renormalize (7610fa5)
   1git-rev-list(1)
   2===============
   3
   4NAME
   5----
   6git-rev-list - Lists commit objects in reverse chronological order
   7
   8
   9SYNOPSIS
  10--------
  11[verse]
  12'git rev-list' [ \--max-count=number ]
  13             [ \--skip=number ]
  14             [ \--max-age=timestamp ]
  15             [ \--min-age=timestamp ]
  16             [ \--sparse ]
  17             [ \--merges ]
  18             [ \--no-merges ]
  19             [ \--first-parent ]
  20             [ \--remove-empty ]
  21             [ \--full-history ]
  22             [ \--not ]
  23             [ \--all ]
  24             [ \--branches[=pattern] ]
  25             [ \--tags[=pattern] ]
  26             [ \--remotes[=pattern] ]
  27             [ \--glob=glob-pattern ]
  28             [ \--stdin ]
  29             [ \--quiet ]
  30             [ \--topo-order ]
  31             [ \--parents ]
  32             [ \--timestamp ]
  33             [ \--left-right ]
  34             [ \--cherry-pick ]
  35             [ \--encoding[=<encoding>] ]
  36             [ \--(author|committer|grep)=<pattern> ]
  37             [ \--regexp-ignore-case | -i ]
  38             [ \--extended-regexp | -E ]
  39             [ \--fixed-strings | -F ]
  40             [ \--date={local|relative|default|iso|rfc|short} ]
  41             [ [\--objects | \--objects-edge] [ \--unpacked ] ]
  42             [ \--pretty | \--header ]
  43             [ \--bisect ]
  44             [ \--bisect-vars ]
  45             [ \--bisect-all ]
  46             [ \--merge ]
  47             [ \--reverse ]
  48             [ \--walk-reflogs ]
  49             [ \--no-walk ] [ \--do-walk ]
  50             <commit>... [ \-- <paths>... ]
  51
  52DESCRIPTION
  53-----------
  54
  55List commits that are reachable by following the `parent` links from the
  56given commit(s), but exclude commits that are reachable from the one(s)
  57given with a '{caret}' in front of them.  The output is given in reverse
  58chronological order by default.
  59
  60You can think of this as a set operation.  Commits given on the command
  61line form a set of commits that are reachable from any of them, and then
  62commits reachable from any of the ones given with '{caret}' in front are
  63subtracted from that set.  The remaining commits are what comes out in the
  64command's output.  Various other options and paths parameters can be used
  65to further limit the result.
  66
  67Thus, the following command:
  68
  69-----------------------------------------------------------------------
  70        $ git rev-list foo bar ^baz
  71-----------------------------------------------------------------------
  72
  73means "list all the commits which are reachable from 'foo' or 'bar', but
  74not from 'baz'".
  75
  76A special notation "'<commit1>'..'<commit2>'" can be used as a
  77short-hand for "{caret}'<commit1>' '<commit2>'". For example, either of
  78the following may be used interchangeably:
  79
  80-----------------------------------------------------------------------
  81        $ git rev-list origin..HEAD
  82        $ git rev-list HEAD ^origin
  83-----------------------------------------------------------------------
  84
  85Another special notation is "'<commit1>'...'<commit2>'" which is useful
  86for merges.  The resulting set of commits is the symmetric difference
  87between the two operands.  The following two commands are equivalent:
  88
  89-----------------------------------------------------------------------
  90        $ git rev-list A B --not $(git merge-base --all A B)
  91        $ git rev-list A...B
  92-----------------------------------------------------------------------
  93
  94'rev-list' is a very essential git command, since it
  95provides the ability to build and traverse commit ancestry graphs. For
  96this reason, it has a lot of different options that enables it to be
  97used by commands as different as 'git bisect' and
  98'git repack'.
  99
 100OPTIONS
 101-------
 102
 103:git-rev-list: 1
 104include::rev-list-options.txt[]
 105
 106include::pretty-formats.txt[]
 107
 108
 109Author
 110------
 111Written by Linus Torvalds <torvalds@osdl.org>
 112
 113Documentation
 114--------------
 115Documentation by David Greaves, Junio C Hamano, Jonas Fonseca
 116and the git-list <git@vger.kernel.org>.
 117
 118GIT
 119---
 120Part of the linkgit:git[1] suite