diff options
author | Junio C Hamano <gitster@pobox.com> | 2021-06-10 12:53:56 +0900 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2021-06-10 12:53:56 +0900 |
commit | 37c77fd2893de182d484f65cca6ba011fe633019 (patch) | |
tree | d0d7faa8ef69c255ae158f80754e3ee1b15fec90 /git-rev-parse.html | |
parent | 7cac38b31559760e4baa97b11aa0356cc96485d4 (diff) | |
download | git-htmldocs-37c77fd2893de182d484f65cca6ba011fe633019.tar.gz |
Autogenerated HTML docs for v2.32.0-29-g211ec
Diffstat (limited to 'git-rev-parse.html')
-rw-r--r-- | git-rev-parse.html | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/git-rev-parse.html b/git-rev-parse.html index e6739d667..93b93666c 100644 --- a/git-rev-parse.html +++ b/git-rev-parse.html @@ -1668,6 +1668,8 @@ commit.</p></div> any of the given commits.</p></div>
<div class="paragraph"><p>A commit’s reachable set is the commit itself and the commits in
its ancestry chain.</p></div>
+<div class="paragraph"><p>There are several notations to specify a set of connected commits
+(called a "revision range"), illustrated below.</p></div>
<div class="sect2">
<h3 id="_commit_exclusions">Commit Exclusions</h3>
<div class="dlist"><dl>
@@ -1718,6 +1720,26 @@ did I do since I forked from the origin branch?" Similarly, <em>..origin</em> is a shorthand for <em>HEAD..origin</em> and asks "What did the origin do since
I forked from them?" Note that <em>..</em> would mean <em>HEAD..HEAD</em> which is an
empty range that is both reachable and unreachable from HEAD.</p></div>
+<div class="paragraph"><p>Commands that are specifically designed to take two distinct ranges
+(e.g. "git range-diff R1 R2" to compare two ranges) do exist, but
+they are exceptions. Unless otherwise noted, all "git" commands
+that operate on a set of commits work on a single revision range.
+In other words, writing two "two-dot range notation" next to each
+other, e.g.</p></div>
+<div class="literalblock">
+<div class="content">
+<pre><code>$ git log A..B C..D</code></pre>
+</div></div>
+<div class="paragraph"><p>does <strong>not</strong> specify two revision ranges for most commands. Instead
+it will name a single connected set of commits, i.e. those that are
+reachable from either B or D but are reachable from neither A or C.
+In a linear history like this:</p></div>
+<div class="literalblock">
+<div class="content">
+<pre><code>---A---B---o---o---C---D</code></pre>
+</div></div>
+<div class="paragraph"><p>because A and B are reachable from C, the revision range specified
+by these two dotted ranges is a single commit D.</p></div>
</div>
<div class="sect2">
<h3 id="_other_lt_rev_gt_94_parent_shorthand_notations">Other <rev>^ Parent Shorthand Notations</h3>
|