summaryrefslogtreecommitdiffstats
path: root/git-log.html
diff options
context:
space:
mode:
Diffstat (limited to 'git-log.html')
-rw-r--r--git-log.html63
1 files changed, 49 insertions, 14 deletions
diff --git a/git-log.html b/git-log.html
index 1ca56b6d5..8ab3c3000 100644
--- a/git-log.html
+++ b/git-log.html
@@ -837,14 +837,28 @@ each commit introduces are shown.</p></div>
</dt>
<dd>
<p>
- If no <code>--decorate-refs</code> is given, pretend as if all refs were
- included. For each candidate, do not use it for decoration if it
+ For each candidate reference, do not use it for decoration if it
matches any patterns given to <code>--decorate-refs-exclude</code> or if it
doesn&#8217;t match any of the patterns given to <code>--decorate-refs</code>. The
<code>log.excludeDecoration</code> config option allows excluding refs from
the decorations, but an explicit <code>--decorate-refs</code> pattern will
override a match in <code>log.excludeDecoration</code>.
</p>
+<div class="paragraph"><p>If none of these options or config settings are given, then references are
+used as decoration if they match <code>HEAD</code>, <code>refs/heads/</code>, <code>refs/remotes/</code>,
+<code>refs/stash/</code>, or <code>refs/tags/</code>.</p></div>
+</dd>
+<dt class="hdlist1">
+--clear-decorations
+</dt>
+<dd>
+<p>
+ When specified, this option clears all previous <code>--decorate-refs</code>
+ or <code>--decorate-refs-exclude</code> options and relaxes the default
+ decoration filter to include all references. This option is
+ assumed if the config value <code>log.initialDecorationSet</code> is set to
+ <code>all</code>.
+</p>
</dd>
<dt class="hdlist1">
--source
@@ -1601,15 +1615,17 @@ Default mode
</p>
</dd>
<dt class="hdlist1">
---ancestry-path
+--ancestry-path[=&lt;commit&gt;]
</dt>
<dd>
<p>
When given a range of commits to display (e.g. <em>commit1..commit2</em>
- or <em>commit2 &#94;commit1</em>), only display commits that exist
- directly on the ancestry chain between the <em>commit1</em> and
- <em>commit2</em>, i.e. commits that are both descendants of <em>commit1</em>,
- and ancestors of <em>commit2</em>.
+ or <em>commit2 &#94;commit1</em>), only display commits in that range
+ that are ancestors of &lt;commit&gt;, descendants of &lt;commit&gt;, or
+ &lt;commit&gt; itself. If no commit is specified, use <em>commit1</em> (the
+ excluded part of the range) as &lt;commit&gt;. Can be passed multiple
+ times; if so, a commit is included if it is any of the commits
+ given or if it is an ancestor or descendant of one of them.
</p>
</dd>
</dl></div>
@@ -1852,14 +1868,13 @@ If after this parent rewriting, <code>C'</code> is a root or merge commit (has
<div class="paragraph"><p>There is another simplification mode available:</p></div>
<div class="dlist"><dl>
<dt class="hdlist1">
---ancestry-path
+--ancestry-path[=&lt;commit&gt;]
</dt>
<dd>
<p>
- Limit the displayed commits to those directly on the ancestry
- chain between the &#8220;from&#8221; and &#8220;to&#8221; commits in the given commit
- range. I.e. only display commits that are ancestor of the &#8220;to&#8221;
- commit and descendants of the &#8220;from&#8221; commit.
+ Limit the displayed commits to those which are an ancestor of
+ &lt;commit&gt;, or which are a descendant of &lt;commit&gt;, or are &lt;commit&gt;
+ itself.
</p>
<div class="paragraph"><p>As an example use case, consider the following commit history:</p></div>
<div class="listingblock">
@@ -1889,6 +1904,26 @@ option does. Applied to the <em>D..M</em> range, it results in:</p></div>
\
L--M</code></pre>
</div></div>
+<div class="paragraph"><p>We can also use <code>--ancestry-path=D</code> instead of <code>--ancestry-path</code> which
+means the same thing when applied to the <em>D..M</em> range but is just more
+explicit.</p></div>
+<div class="paragraph"><p>If we instead are interested in a given topic within this range, and all
+commits affected by that topic, we may only want to view the subset of
+<code>D..M</code> which contain that topic in their ancestry path. So, using
+<code>--ancestry-path=H D..M</code> for example would result in:</p></div>
+<div class="listingblock">
+<div class="content">
+<pre><code> E
+ \
+ G---H---I---J
+ \
+ L--M</code></pre>
+</div></div>
+<div class="paragraph"><p>Whereas <code>--ancestry-path=K D..M</code> would result in</p></div>
+<div class="listingblock">
+<div class="content">
+<pre><code> K---------------L--M</code></pre>
+</div></div>
</dd>
</dl></div>
<div class="paragraph"><p>Before discussing another option, <code>--show-pulls</code>, we need to
@@ -1940,7 +1975,7 @@ merge commits <code>O</code> and <code>P</code>. With parent rewriting, the resu
not actually contribute a change to <code>file.txt</code>. They only merged a topic
that was based on an older version of <code>file.txt</code>. This is a common
issue in repositories using a workflow where many contributors work in
-parallel and merge their topic branches along a single trunk: manu
+parallel and merge their topic branches along a single trunk: many
unrelated merges appear in the <code>--full-history</code> results.</p></div>
<div class="paragraph"><p>When using the <code>--simplify-merges</code> option, the commits <code>O</code> and <code>P</code>
disappear from the results. This is because the rewritten second parents
@@ -5384,7 +5419,7 @@ and overridden by the <code>--notes=&lt;ref&gt;</code> option.</p></div>
<div id="footer">
<div id="footer-text">
Last updated
- 2021-12-10 14:52:02 PST
+ 2022-08-30 10:56:31 PDT
</div>
</div>
</body>