summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2023-10-13 15:27:26 -0700
committerJunio C Hamano <gitster@pobox.com>2023-10-13 15:27:26 -0700
commitc05b7640bc119b3f3a12aec0a205031f9907613b (patch)
treec0c11a4310650c8a5591d0a7e7638e7cbdcb9df3
parentcf4e19832ce232635706fbb597557a21e1cb181a (diff)
downloadgit-htmldocs-c05b7640bc119b3f3a12aec0a205031f9907613b.tar.gz
Autogenerated HTML docs for v2.42.0-398-ga9ecd
-rw-r--r--MyFirstContribution.html2
-rw-r--r--MyFirstObjectWalk.html2
-rw-r--r--RelNotes/2.43.0.txt21
-rw-r--r--ReviewingGuidelines.html2
-rw-r--r--SubmittingPatches.html2
-rw-r--r--ToolsForGit.html2
-rw-r--r--everyday.html2
-rw-r--r--git-interpret-trailers.html181
-rw-r--r--git-interpret-trailers.txt183
-rw-r--r--git-remote-helpers.html2
-rw-r--r--howto/coordinate-embargoed-releases.html2
-rw-r--r--howto/keep-canonical-history-correct.html4
-rw-r--r--howto/maintain-git.html4
-rw-r--r--howto/new-command.html4
-rw-r--r--howto/rebase-from-internal-branch.html4
-rw-r--r--howto/rebuild-from-update-hook.html4
-rw-r--r--howto/recover-corrupted-blob-object.html4
-rw-r--r--howto/recover-corrupted-object-harder.html4
-rw-r--r--howto/revert-a-faulty-merge.html4
-rw-r--r--howto/revert-branch-rebase.html4
-rw-r--r--howto/separating-topic-branches.html4
-rw-r--r--howto/setup-git-server-over-http.html4
-rw-r--r--howto/update-hook-example.html4
-rw-r--r--howto/use-git-daemon.html4
-rw-r--r--howto/using-merge-subtree.html4
-rw-r--r--howto/using-signed-tag-in-pull-request.html4
-rw-r--r--technical/api-error-handling.html2
-rw-r--r--technical/api-index.html2
-rw-r--r--technical/api-merge.html2
-rw-r--r--technical/api-parse-options.html2
-rw-r--r--technical/api-simple-ipc.html2
-rw-r--r--technical/api-trace2.html2
-rw-r--r--technical/bitmap-format.html2
-rw-r--r--technical/bundle-uri.html2
-rw-r--r--technical/hash-function-transition.html2
-rw-r--r--technical/long-running-process-protocol.html2
-rw-r--r--technical/multi-pack-index.html2
-rw-r--r--technical/pack-heuristics.html2
-rw-r--r--technical/parallel-checkout.html2
-rw-r--r--technical/partial-clone.html2
-rw-r--r--technical/racy-git.html2
-rw-r--r--technical/scalar.html2
-rw-r--r--technical/send-pack-pipeline.html2
-rw-r--r--technical/shallow.html2
-rw-r--r--technical/trivial-merge.html2
-rw-r--r--user-manual.html2
46 files changed, 292 insertions, 209 deletions
diff --git a/MyFirstContribution.html b/MyFirstContribution.html
index 4a990df36..bd2784e11 100644
--- a/MyFirstContribution.html
+++ b/MyFirstContribution.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>My First Contribution to the Git Project</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div class="sect1">
diff --git a/MyFirstObjectWalk.html b/MyFirstObjectWalk.html
index d394741c0..134e4cdaa 100644
--- a/MyFirstObjectWalk.html
+++ b/MyFirstObjectWalk.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>My First Object Walk</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div class="sect1">
diff --git a/RelNotes/2.43.0.txt b/RelNotes/2.43.0.txt
index a6ed55488..6abdf8bf6 100644
--- a/RelNotes/2.43.0.txt
+++ b/RelNotes/2.43.0.txt
@@ -86,6 +86,8 @@ UI, Workflows & Features
* "git repack" machinery learns to pay attention to the "--filter="
option.
+ * Test coverage for trailers has been improved.
+
Performance, Internal Implementation, Development Support etc.
@@ -223,6 +225,24 @@ Fixes since v2.42
Unicode 15.1
(merge 872976c37e bb/unicode-width-table-15 later to maint).
+ * Update mailmap entry for Derrick.
+ (merge 6e5457d8c7 ds/mailmap-entry-update later to maint).
+
+ * In .gitmodules files, submodules are keyed by their names, and the
+ path to the submodule whose name is $name is specified by the
+ submodule.$name.path variable. There were a few codepaths that
+ mixed the name and path up when consulting the submodule database,
+ which have been corrected. It took long for these bugs to be found
+ as the name of a submodule initially is the same as its path, and
+ the problem does not surface until it is moved to a different path,
+ which apparently happens very rarely.
+
+ * "git diff --merge-base X other args..." insisted that X must be a
+ commit and errored out when given an annotated tag that peels to a
+ commit, but we only need it to be a committish. This has been
+ corrected.
+ (merge 4adceb5a29 ar/diff-index-merge-base-fix later to maint).
+
* Other code cleanup, docfix, build fix, etc.
(merge fd3ba590d8 ws/git-push-doc-grammofix later to maint).
(merge 5f33a843de ds/upload-pack-error-sequence-fix later to maint).
@@ -245,3 +265,4 @@ Fixes since v2.42
(merge 43abaaf008 ob/am-msgfix later to maint).
(merge c2c349a15c xz/commit-title-soft-limit-doc later to maint).
(merge f4cbb32c27 rs/parse-opt-ctx-cleanup later to maint).
+ (merge badf2fe1c3 jk/decoration-and-other-leak-fixes later to maint).
diff --git a/ReviewingGuidelines.html b/ReviewingGuidelines.html
index 67708a5da..332ace606 100644
--- a/ReviewingGuidelines.html
+++ b/ReviewingGuidelines.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>Reviewing Patches in the Git Project</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div class="sect1">
diff --git a/SubmittingPatches.html b/SubmittingPatches.html
index 59c859e6c..31264fd88 100644
--- a/SubmittingPatches.html
+++ b/SubmittingPatches.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>Submitting Patches</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div class="sect1">
diff --git a/ToolsForGit.html b/ToolsForGit.html
index d3e49afd4..928c756db 100644
--- a/ToolsForGit.html
+++ b/ToolsForGit.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>Tools for developing Git</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div class="sect1">
diff --git a/everyday.html b/everyday.html
index 028472b65..88497dee5 100644
--- a/everyday.html
+++ b/everyday.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>Everyday Git With 20 Commands Or So</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div id="preamble">
diff --git a/git-interpret-trailers.html b/git-interpret-trailers.html
index d26868bc5..32ee9a6d0 100644
--- a/git-interpret-trailers.html
+++ b/git-interpret-trailers.html
@@ -750,7 +750,7 @@ git-interpret-trailers(1) Manual Page
<div class="sectionbody">
<div class="verseblock">
<pre class="content"><em>git interpret-trailers</em> [--in-place] [--trim-empty]
- [(--trailer &lt;token&gt;[(=|:)&lt;value&gt;])&#8230;]
+ [(--trailer (&lt;key&gt;|&lt;keyAlias&gt;)[(=|:)&lt;value&gt;])&#8230;]
[--parse] [&lt;file&gt;&#8230;]</pre>
<div class="attribution">
</div></div>
@@ -774,10 +774,14 @@ Signed-off-by: Bob &lt;bob@example.com&gt;</code></pre>
<div class="paragraph"><p>the last two lines starting with "Signed-off-by" are trailers.</p></div>
<div class="paragraph"><p>This command reads commit messages from either the
&lt;file&gt; arguments or the standard input if no &lt;file&gt; is specified.
-If <code>--parse</code> is specified, the output consists of the parsed trailers.
-Otherwise, this command applies the arguments passed using the
-<code>--trailer</code> option, if any, to each input file. The result is emitted on the
-standard output.</p></div>
+If <code>--parse</code> is specified, the output consists of the parsed trailers
+coming from the input, without influencing them with any command line
+options or configuration variables.</p></div>
+<div class="paragraph"><p>Otherwise, this command applies <code>trailer.*</code> configuration variables
+(which could potentially add new trailers, as well as reposition them),
+as well as any command line arguments that can override configuration
+variables (such as <code>--trailer=...</code> which could also add new trailers),
+to each input file. The result is emitted on the standard output.</p></div>
<div class="paragraph"><p>This command can also operate on the output of <a href="git-format-patch.html">git-format-patch(1)</a>,
which is more elaborate than a plain commit message. Namely, such output
includes a commit message (as above), a "---" divider line, and a patch part.
@@ -788,21 +792,29 @@ this command and are emitted as is on the output, unless
are applied to each input and the way any existing trailer in
the input is changed. They also make it possible to
automatically add some trailers.</p></div>
-<div class="paragraph"><p>By default, a <em>&lt;token&gt;=&lt;value&gt;</em> or <em>&lt;token&gt;:&lt;value&gt;</em> argument given
+<div class="paragraph"><p>By default, a <em>&lt;key&gt;=&lt;value&gt;</em> or <em>&lt;key&gt;:&lt;value&gt;</em> argument given
using <code>--trailer</code> will be appended after the existing trailers only if
-the last trailer has a different (&lt;token&gt;, &lt;value&gt;) pair (or if there
-is no existing trailer). The &lt;token&gt; and &lt;value&gt; parts will be trimmed
+the last trailer has a different (&lt;key&gt;, &lt;value&gt;) pair (or if there
+is no existing trailer). The &lt;key&gt; and &lt;value&gt; parts will be trimmed
to remove starting and trailing whitespace, and the resulting trimmed
-&lt;token&gt; and &lt;value&gt; will appear in the output like this:</p></div>
+&lt;key&gt; and &lt;value&gt; will appear in the output like this:</p></div>
<div class="listingblock">
<div class="content">
-<pre><code>token: value</code></pre>
+<pre><code>key: value</code></pre>
</div></div>
-<div class="paragraph"><p>This means that the trimmed &lt;token&gt; and &lt;value&gt; will be separated by
-<code>': '</code> (one colon followed by one space). For convenience, the &lt;token&gt; can be a
-shortened string key (e.g., "sign") instead of the full string which should
-appear before the separator on the output (e.g., "Signed-off-by"). This can be
-configured using the <em>trailer.&lt;token&gt;.key</em> configuration variable.</p></div>
+<div class="paragraph"><p>This means that the trimmed &lt;key&gt; and &lt;value&gt; will be separated by
+<code>': '</code> (one colon followed by one space).</p></div>
+<div class="paragraph"><p>For convenience, a &lt;keyAlias&gt; can be configured to make using <code>--trailer</code>
+shorter to type on the command line. This can be configured using the
+<em>trailer.&lt;keyAlias&gt;.key</em> configuration variable. The &lt;keyAlias&gt; must be a prefix
+of the full &lt;key&gt; string, although case sensitivity does not matter. For
+example, if you have</p></div>
+<div class="listingblock">
+<div class="content">
+<pre><code>trailer.sign.key "Signed-off-by: "</code></pre>
+</div></div>
+<div class="paragraph"><p>in your configuration, you only need to specify <code>--trailer="sign: foo"</code>
+on the command line instead of <code>--trailer="Signed-off-by: foo"</code>.</p></div>
<div class="paragraph"><p>By default the new trailer will appear at the end of all the existing
trailers. If there is no existing trailer, the new trailer will appear
at the end of the input. A blank line will be added before the new
@@ -816,14 +828,14 @@ The group must either be at the end of the input or be the last
non-whitespace lines before a line that starts with <em>---</em> (followed by a
space or the end of the line).</p></div>
<div class="paragraph"><p>When reading trailers, there can be no whitespace before or inside the
-&lt;token&gt;, but any number of regular space and tab characters are allowed
-between the &lt;token&gt; and the separator. There can be whitespaces before,
+&lt;key&gt;, but any number of regular space and tab characters are allowed
+between the &lt;key&gt; and the separator. There can be whitespaces before,
inside or after the &lt;value&gt;. The &lt;value&gt; may be split over multiple lines
with each subsequent line starting with at least one whitespace, like
the "folding" in RFC 822. Example:</p></div>
<div class="listingblock">
<div class="content">
-<pre><code>token: This is a very long value, with spaces and
+<pre><code>key: This is a very long value, with spaces and
newlines in it.</code></pre>
</div></div>
<div class="paragraph"><p>Note that trailers do not follow (nor are they intended to follow) many of the
@@ -853,11 +865,11 @@ rules for RFC 822 headers. For example they do not follow the encoding rule.</p>
</p>
</dd>
<dt class="hdlist1">
---trailer &lt;token&gt;[(=|:)&lt;value&gt;]
+--trailer &lt;key&gt;[(=|:)&lt;value&gt;]
</dt>
<dd>
<p>
- Specify a (&lt;token&gt;, &lt;value&gt;) pair that should be applied as a
+ Specify a (&lt;key&gt;, &lt;value&gt;) pair that should be applied as a
trailer to the inputs. See the description of this
command.
</p>
@@ -871,10 +883,13 @@ rules for RFC 822 headers. For example they do not follow the encoding rule.</p>
<dd>
<p>
Specify where all new trailers will be added. A setting
- provided with <em>--where</em> overrides all configuration variables
+ provided with <em>--where</em> overrides the <code>trailer.where</code> and any
+ applicable <code>trailer.&lt;keyAlias&gt;.where</code> configuration variables
and applies to all <em>--trailer</em> options until the next occurrence of
- <em>--where</em> or <em>--no-where</em>. Possible values are <code>after</code>, <code>before</code>,
- <code>end</code> or <code>start</code>.
+ <em>--where</em> or <em>--no-where</em>. Upon encountering <em>--no-where</em>, clear the
+ effect of any previous use of <em>--where</em>, such that the relevant configuration
+ variables are no longer overridden. Possible placements are <code>after</code>,
+ <code>before</code>, <code>end</code> or <code>start</code>.
</p>
</dd>
<dt class="hdlist1">
@@ -886,10 +901,13 @@ rules for RFC 822 headers. For example they do not follow the encoding rule.</p>
<dd>
<p>
Specify what action will be performed when there is already at
- least one trailer with the same &lt;token&gt; in the input. A setting
- provided with <em>--if-exists</em> overrides all configuration variables
+ least one trailer with the same &lt;key&gt; in the input. A setting
+ provided with <em>--if-exists</em> overrides the <code>trailer.ifExists</code> and any
+ applicable <code>trailer.&lt;keyAlias&gt;.ifExists</code> configuration variables
and applies to all <em>--trailer</em> options until the next occurrence of
- <em>--if-exists</em> or <em>--no-if-exists</em>. Possible actions are <code>addIfDifferent</code>,
+ <em>--if-exists</em> or <em>--no-if-exists</em>. Upon encountering '--no-if-exists, clear the
+ effect of any previous use of '--if-exists, such that the relevant configuration
+ variables are no longer overridden. Possible actions are <code>addIfDifferent</code>,
<code>addIfDifferentNeighbor</code>, <code>add</code>, <code>replace</code> and <code>doNothing</code>.
</p>
</dd>
@@ -902,10 +920,13 @@ rules for RFC 822 headers. For example they do not follow the encoding rule.</p>
<dd>
<p>
Specify what action will be performed when there is no other
- trailer with the same &lt;token&gt; in the input. A setting
- provided with <em>--if-missing</em> overrides all configuration variables
+ trailer with the same &lt;key&gt; in the input. A setting
+ provided with <em>--if-missing</em> overrides the <code>trailer.ifMissing</code> and any
+ applicable <code>trailer.&lt;keyAlias&gt;.ifMissing</code> configuration variables
and applies to all <em>--trailer</em> options until the next occurrence of
- <em>--if-missing</em> or <em>--no-if-missing</em>. Possible actions are <code>doNothing</code>
+ <em>--if-missing</em> or <em>--no-if-missing</em>. Upon encountering '--no-if-missing,
+ clear the effect of any previous use of '--if-missing, such that the relevant
+ configuration variables are no longer overridden. Possible actions are <code>doNothing</code>
or <code>add</code>.
</p>
</dd>
@@ -923,8 +944,8 @@ rules for RFC 822 headers. For example they do not follow the encoding rule.</p>
<dd>
<p>
Output only trailers that exist in the input; do not add any
- from the command-line or by following configured <code>trailer.*</code>
- rules.
+ from the command-line or by applying <code>trailer.*</code> configuration
+ variables.
</p>
</dd>
<dt class="hdlist1">
@@ -932,8 +953,8 @@ rules for RFC 822 headers. For example they do not follow the encoding rule.</p>
</dt>
<dd>
<p>
- Remove any whitespace-continuation in trailers, so that each
- trailer appears on a line by itself with its full content.
+ If a trailer has a value that runs over multiple lines (aka "folded"),
+ reformat the value into a single line.
</p>
</dd>
<dt class="hdlist1">
@@ -942,7 +963,10 @@ rules for RFC 822 headers. For example they do not follow the encoding rule.</p>
<dd>
<p>
A convenience alias for <code>--only-trailers --only-input
- --unfold</code>.
+ --unfold</code>. This makes it easier to only see the trailers coming from the
+ input without influencing them with any command line options or
+ configuration variables, while also making the output machine-friendly with
+ --unfold.
</p>
</dd>
<dt class="hdlist1">
@@ -976,11 +1000,11 @@ trailer.separators
used when another separator is not specified in the config for this
trailer.</p></div>
<div class="paragraph"><p>For example, if the value for this option is "%=$", then only lines
-using the format <em>&lt;token&gt;&lt;sep&gt;&lt;value&gt;</em> with &lt;sep&gt; containing <em>%</em>, <em>=</em>
+using the format <em>&lt;key&gt;&lt;sep&gt;&lt;value&gt;</em> with &lt;sep&gt; containing <em>%</em>, <em>=</em>
or <em>$</em> and then spaces will be considered trailers. And <em>%</em> will be
the default separator used, so by default trailers will appear like:
-<em>&lt;token&gt;% &lt;value&gt;</em> (one percent sign and one space will appear between
-the token and the value).</p></div>
+<em>&lt;key&gt;% &lt;value&gt;</em> (one percent sign and one space will appear between
+the key and the value).</p></div>
</dd>
<dt class="hdlist1">
trailer.where
@@ -995,9 +1019,9 @@ existing trailers.</p></div>
<div class="paragraph"><p>If it is <code>start</code>, then each new trailer will appear at the start,
instead of the end, of the existing trailers.</p></div>
<div class="paragraph"><p>If it is <code>after</code>, then each new trailer will appear just after the
-last trailer with the same &lt;token&gt;.</p></div>
+last trailer with the same &lt;key&gt;.</p></div>
<div class="paragraph"><p>If it is <code>before</code>, then each new trailer will appear just before the
-first trailer with the same &lt;token&gt;.</p></div>
+first trailer with the same &lt;key&gt;.</p></div>
</dd>
<dt class="hdlist1">
trailer.ifexists
@@ -1006,23 +1030,23 @@ trailer.ifexists
<p>
This option makes it possible to choose what action will be
performed when there is already at least one trailer with the
- same &lt;token&gt; in the input.
+ same &lt;key&gt; in the input.
</p>
<div class="paragraph"><p>The valid values for this option are: <code>addIfDifferentNeighbor</code> (this
is the default), <code>addIfDifferent</code>, <code>add</code>, <code>replace</code> or <code>doNothing</code>.</p></div>
<div class="paragraph"><p>With <code>addIfDifferentNeighbor</code>, a new trailer will be added only if no
-trailer with the same (&lt;token&gt;, &lt;value&gt;) pair is above or below the line
+trailer with the same (&lt;key&gt;, &lt;value&gt;) pair is above or below the line
where the new trailer will be added.</p></div>
<div class="paragraph"><p>With <code>addIfDifferent</code>, a new trailer will be added only if no trailer
-with the same (&lt;token&gt;, &lt;value&gt;) pair is already in the input.</p></div>
+with the same (&lt;key&gt;, &lt;value&gt;) pair is already in the input.</p></div>
<div class="paragraph"><p>With <code>add</code>, a new trailer will be added, even if some trailers with
-the same (&lt;token&gt;, &lt;value&gt;) pair are already in the input.</p></div>
-<div class="paragraph"><p>With <code>replace</code>, an existing trailer with the same &lt;token&gt; will be
+the same (&lt;key&gt;, &lt;value&gt;) pair are already in the input.</p></div>
+<div class="paragraph"><p>With <code>replace</code>, an existing trailer with the same &lt;key&gt; will be
deleted and the new trailer will be added. The deleted trailer will be
-the closest one (with the same &lt;token&gt;) to the place where the new one
+the closest one (with the same &lt;key&gt;) to the place where the new one
will be added.</p></div>
<div class="paragraph"><p>With <code>doNothing</code>, nothing will be done; that is no new trailer will be
-added if there is already one with the same &lt;token&gt; in the input.</p></div>
+added if there is already one with the same &lt;key&gt; in the input.</p></div>
</dd>
<dt class="hdlist1">
trailer.ifmissing
@@ -1031,7 +1055,7 @@ trailer.ifmissing
<p>
This option makes it possible to choose what action will be
performed when there is not yet any trailer with the same
- &lt;token&gt; in the input.
+ &lt;key&gt; in the input.
</p>
<div class="paragraph"><p>The valid values for this option are: <code>add</code> (this is the default) and
<code>doNothing</code>.</p></div>
@@ -1039,88 +1063,93 @@ trailer.ifmissing
<div class="paragraph"><p>With <code>doNothing</code>, nothing will be done.</p></div>
</dd>
<dt class="hdlist1">
-trailer.&lt;token&gt;.key
+trailer.&lt;keyAlias&gt;.key
</dt>
<dd>
<p>
- This <code>key</code> will be used instead of &lt;token&gt; in the trailer. At
- the end of this key, a separator can appear and then some
- space characters. By default the only valid separator is <em>:</em>,
- but this can be changed using the <code>trailer.separators</code> config
- variable.
+ Defines a &lt;keyAlias&gt; for the &lt;key&gt;. The &lt;keyAlias&gt; must be a
+ prefix (case does not matter) of the &lt;key&gt;. For example, in <code>git
+ config trailer.ack.key "Acked-by"</code> the "Acked-by" is the &lt;key&gt; and
+ the "ack" is the &lt;keyAlias&gt;. This configuration allows the shorter
+ <code>--trailer "ack:..."</code> invocation on the command line using the "ack"
+ &lt;keyAlias&gt; instead of the longer <code>--trailer "Acked-by:..."</code>.
</p>
-<div class="paragraph"><p>If there is a separator, then the key will be used instead of both the
-&lt;token&gt; and the default separator when adding the trailer.</p></div>
+<div class="paragraph"><p>At the end of the &lt;key&gt;, a separator can appear and then some
+space characters. By default the only valid separator is <em>:</em>,
+but this can be changed using the <code>trailer.separators</code> config
+variable.</p></div>
+<div class="paragraph"><p>If there is a separator in the key, then it overrides the default
+separator when adding the trailer.</p></div>
</dd>
<dt class="hdlist1">
-trailer.&lt;token&gt;.where
+trailer.&lt;keyAlias&gt;.where
</dt>
<dd>
<p>
This option takes the same values as the <em>trailer.where</em>
configuration variable and it overrides what is specified by
- that option for trailers with the specified &lt;token&gt;.
+ that option for trailers with the specified &lt;keyAlias&gt;.
</p>
</dd>
<dt class="hdlist1">
-trailer.&lt;token&gt;.ifexists
+trailer.&lt;keyAlias&gt;.ifexists
</dt>
<dd>
<p>
This option takes the same values as the <em>trailer.ifexists</em>
configuration variable and it overrides what is specified by
- that option for trailers with the specified &lt;token&gt;.
+ that option for trailers with the specified &lt;keyAlias&gt;.
</p>
</dd>
<dt class="hdlist1">
-trailer.&lt;token&gt;.ifmissing
+trailer.&lt;keyAlias&gt;.ifmissing
</dt>
<dd>
<p>
This option takes the same values as the <em>trailer.ifmissing</em>
configuration variable and it overrides what is specified by
- that option for trailers with the specified &lt;token&gt;.
+ that option for trailers with the specified &lt;keyAlias&gt;.
</p>
</dd>
<dt class="hdlist1">
-trailer.&lt;token&gt;.command
+trailer.&lt;keyAlias&gt;.command
</dt>
<dd>
<p>
- Deprecated in favor of <em>trailer.&lt;token&gt;.cmd</em>.
- This option behaves in the same way as <em>trailer.&lt;token&gt;.cmd</em>, except
+ Deprecated in favor of <em>trailer.&lt;keyAlias&gt;.cmd</em>.
+ This option behaves in the same way as <em>trailer.&lt;keyAlias&gt;.cmd</em>, except
that it doesn&#8217;t pass anything as argument to the specified command.
Instead the first occurrence of substring $ARG is replaced by the
&lt;value&gt; that would be passed as argument.
</p>
<div class="paragraph"><p>Note that $ARG in the user&#8217;s command is
only replaced once and that the original way of replacing $ARG is not safe.</p></div>
-<div class="paragraph"><p>When both <em>trailer.&lt;token&gt;.cmd</em> and <em>trailer.&lt;token&gt;.command</em> are given
-for the same &lt;token&gt;, <em>trailer.&lt;token&gt;.cmd</em> is used and
-<em>trailer.&lt;token&gt;.command</em> is ignored.</p></div>
+<div class="paragraph"><p>When both <em>trailer.&lt;keyAlias&gt;.cmd</em> and <em>trailer.&lt;keyAlias&gt;.command</em> are given
+for the same &lt;keyAlias&gt;, <em>trailer.&lt;keyAlias&gt;.cmd</em> is used and
+<em>trailer.&lt;keyAlias&gt;.command</em> is ignored.</p></div>
</dd>
<dt class="hdlist1">
-trailer.&lt;token&gt;.cmd
+trailer.&lt;keyAlias&gt;.cmd
</dt>
<dd>
<p>
This option can be used to specify a shell command that will be called
- once to automatically add a trailer with the specified &lt;token&gt;, and then
- called each time a <em>--trailer &lt;token&gt;=&lt;value&gt;</em> argument is specified to
+ once to automatically add a trailer with the specified &lt;keyAlias&gt;, and then
+ called each time a <em>--trailer &lt;keyAlias&gt;=&lt;value&gt;</em> argument is specified to
modify the &lt;value&gt; of the trailer that this option would produce.
</p>
<div class="paragraph"><p>When the specified command is first called to add a trailer
-with the specified &lt;token&gt;, the behavior is as if a special
-<em>--trailer &lt;token&gt;=&lt;value&gt;</em> argument was added at the beginning
+with the specified &lt;keyAlias&gt;, the behavior is as if a special
+<em>--trailer &lt;keyAlias&gt;=&lt;value&gt;</em> argument was added at the beginning
of the "git interpret-trailers" command, where &lt;value&gt;
is taken to be the standard output of the command with any
leading and trailing whitespace trimmed off.</p></div>
-<div class="paragraph"><p>If some <em>--trailer &lt;token&gt;=&lt;value&gt;</em> arguments are also passed
+<div class="paragraph"><p>If some <em>--trailer &lt;keyAlias&gt;=&lt;value&gt;</em> arguments are also passed
on the command line, the command is called again once for each
-of these arguments with the same &lt;token&gt;. And the &lt;value&gt; part
+of these arguments with the same &lt;keyAlias&gt;. And the &lt;value&gt; part
of these arguments, if any, will be passed to the command as its
first argument. This way the command can produce a &lt;value&gt; computed
-from the &lt;value&gt; passed in the <em>--trailer &lt;token&gt;=&lt;value&gt;</em> argument.</p></div>
+from the &lt;value&gt; passed in the <em>--trailer &lt;keyAlias&gt;=&lt;value&gt;</em> argument.</p></div>
</dd>
</dl></div>
</div>
@@ -1364,7 +1393,7 @@ $ chmod +x .git/hooks/commit-msg</code></pre>
<div id="footer">
<div id="footer-text">
Last updated
- 2023-06-23 13:24:09 PDT
+ 2023-10-13 15:25:25 PDT
</div>
</div>
</body>
diff --git a/git-interpret-trailers.txt b/git-interpret-trailers.txt
index 55d896146..418265f04 100644
--- a/git-interpret-trailers.txt
+++ b/git-interpret-trailers.txt
@@ -9,7 +9,7 @@ SYNOPSIS
--------
[verse]
'git interpret-trailers' [--in-place] [--trim-empty]
- [(--trailer <token>[(=|:)<value>])...]
+ [(--trailer (<key>|<keyAlias>)[(=|:)<value>])...]
[--parse] [<file>...]
DESCRIPTION
@@ -31,10 +31,15 @@ the last two lines starting with "Signed-off-by" are trailers.
This command reads commit messages from either the
<file> arguments or the standard input if no <file> is specified.
-If `--parse` is specified, the output consists of the parsed trailers.
-Otherwise, this command applies the arguments passed using the
-`--trailer` option, if any, to each input file. The result is emitted on the
-standard output.
+If `--parse` is specified, the output consists of the parsed trailers
+coming from the input, without influencing them with any command line
+options or configuration variables.
+
+Otherwise, this command applies `trailer.*` configuration variables
+(which could potentially add new trailers, as well as reposition them),
+as well as any command line arguments that can override configuration
+variables (such as `--trailer=...` which could also add new trailers),
+to each input file. The result is emitted on the standard output.
This command can also operate on the output of linkgit:git-format-patch[1],
which is more elaborate than a plain commit message. Namely, such output
@@ -48,22 +53,32 @@ are applied to each input and the way any existing trailer in
the input is changed. They also make it possible to
automatically add some trailers.
-By default, a '<token>=<value>' or '<token>:<value>' argument given
+By default, a '<key>=<value>' or '<key>:<value>' argument given
using `--trailer` will be appended after the existing trailers only if
-the last trailer has a different (<token>, <value>) pair (or if there
-is no existing trailer). The <token> and <value> parts will be trimmed
+the last trailer has a different (<key>, <value>) pair (or if there
+is no existing trailer). The <key> and <value> parts will be trimmed
to remove starting and trailing whitespace, and the resulting trimmed
-<token> and <value> will appear in the output like this:
+<key> and <value> will appear in the output like this:
------------------------------------------------
-token: value
+key: value
------------------------------------------------
-This means that the trimmed <token> and <value> will be separated by
-`': '` (one colon followed by one space). For convenience, the <token> can be a
-shortened string key (e.g., "sign") instead of the full string which should
-appear before the separator on the output (e.g., "Signed-off-by"). This can be
-configured using the 'trailer.<token>.key' configuration variable.
+This means that the trimmed <key> and <value> will be separated by
+`': '` (one colon followed by one space).
+
+For convenience, a <keyAlias> can be configured to make using `--trailer`
+shorter to type on the command line. This can be configured using the
+'trailer.<keyAlias>.key' configuration variable. The <keyAlias> must be a prefix
+of the full <key> string, although case sensitivity does not matter. For
+example, if you have
+
+------------------------------------------------
+trailer.sign.key "Signed-off-by: "
+------------------------------------------------
+
+in your configuration, you only need to specify `--trailer="sign: foo"`
+on the command line instead of `--trailer="Signed-off-by: foo"`.
By default the new trailer will appear at the end of all the existing
trailers. If there is no existing trailer, the new trailer will appear
@@ -80,14 +95,14 @@ non-whitespace lines before a line that starts with '---' (followed by a
space or the end of the line).
When reading trailers, there can be no whitespace before or inside the
-<token>, but any number of regular space and tab characters are allowed
-between the <token> and the separator. There can be whitespaces before,
+<key>, but any number of regular space and tab characters are allowed
+between the <key> and the separator. There can be whitespaces before,
inside or after the <value>. The <value> may be split over multiple lines
with each subsequent line starting with at least one whitespace, like
the "folding" in RFC 822. Example:
------------------------------------------------
-token: This is a very long value, with spaces and
+key: This is a very long value, with spaces and
newlines in it.
------------------------------------------------
@@ -104,35 +119,44 @@ OPTIONS
the whole trailer will be removed from the output.
This applies to existing trailers as well as new trailers.
---trailer <token>[(=|:)<value>]::
- Specify a (<token>, <value>) pair that should be applied as a
+--trailer <key>[(=|:)<value>]::
+ Specify a (<key>, <value>) pair that should be applied as a
trailer to the inputs. See the description of this
command.
--where <placement>::
--no-where::
Specify where all new trailers will be added. A setting
- provided with '--where' overrides all configuration variables
+ provided with '--where' overrides the `trailer.where` and any
+ applicable `trailer.<keyAlias>.where` configuration variables
and applies to all '--trailer' options until the next occurrence of
- '--where' or '--no-where'. Possible values are `after`, `before`,
- `end` or `start`.
+ '--where' or '--no-where'. Upon encountering '--no-where', clear the
+ effect of any previous use of '--where', such that the relevant configuration
+ variables are no longer overridden. Possible placements are `after`,
+ `before`, `end` or `start`.
--if-exists <action>::
--no-if-exists::
Specify what action will be performed when there is already at
- least one trailer with the same <token> in the input. A setting
- provided with '--if-exists' overrides all configuration variables
+ least one trailer with the same <key> in the input. A setting
+ provided with '--if-exists' overrides the `trailer.ifExists` and any
+ applicable `trailer.<keyAlias>.ifExists` configuration variables
and applies to all '--trailer' options until the next occurrence of
- '--if-exists' or '--no-if-exists'. Possible actions are `addIfDifferent`,
+ '--if-exists' or '--no-if-exists'. Upon encountering '--no-if-exists, clear the
+ effect of any previous use of '--if-exists, such that the relevant configuration
+ variables are no longer overridden. Possible actions are `addIfDifferent`,
`addIfDifferentNeighbor`, `add`, `replace` and `doNothing`.
--if-missing <action>::
--no-if-missing::
Specify what action will be performed when there is no other
- trailer with the same <token> in the input. A setting
- provided with '--if-missing' overrides all configuration variables
+ trailer with the same <key> in the input. A setting
+ provided with '--if-missing' overrides the `trailer.ifMissing` and any
+ applicable `trailer.<keyAlias>.ifMissing` configuration variables
and applies to all '--trailer' options until the next occurrence of
- '--if-missing' or '--no-if-missing'. Possible actions are `doNothing`
+ '--if-missing' or '--no-if-missing'. Upon encountering '--no-if-missing,
+ clear the effect of any previous use of '--if-missing, such that the relevant
+ configuration variables are no longer overridden. Possible actions are `doNothing`
or `add`.
--only-trailers::
@@ -140,16 +164,19 @@ OPTIONS
--only-input::
Output only trailers that exist in the input; do not add any
- from the command-line or by following configured `trailer.*`
- rules.
+ from the command-line or by applying `trailer.*` configuration
+ variables.
--unfold::
- Remove any whitespace-continuation in trailers, so that each
- trailer appears on a line by itself with its full content.
+ If a trailer has a value that runs over multiple lines (aka "folded"),
+ reformat the value into a single line.
--parse::
A convenience alias for `--only-trailers --only-input
- --unfold`.
+ --unfold`. This makes it easier to only see the trailers coming from the
+ input without influencing them with any command line options or
+ configuration variables, while also making the output machine-friendly with
+ --unfold.
--no-divider::
Do not treat `---` as the end of the commit message. Use this
@@ -170,11 +197,11 @@ used when another separator is not specified in the config for this
trailer.
+
For example, if the value for this option is "%=$", then only lines
-using the format '<token><sep><value>' with <sep> containing '%', '='
+using the format '<key><sep><value>' with <sep> containing '%', '='
or '$' and then spaces will be considered trailers. And '%' will be
the default separator used, so by default trailers will appear like:
-'<token>% <value>' (one percent sign and one space will appear between
-the token and the value).
+'<key>% <value>' (one percent sign and one space will appear between
+the key and the value).
trailer.where::
This option tells where a new trailer will be added.
@@ -188,41 +215,41 @@ If it is `start`, then each new trailer will appear at the start,
instead of the end, of the existing trailers.
+
If it is `after`, then each new trailer will appear just after the
-last trailer with the same <token>.
+last trailer with the same <key>.
+
If it is `before`, then each new trailer will appear just before the
-first trailer with the same <token>.
+first trailer with the same <key>.
trailer.ifexists::
This option makes it possible to choose what action will be
performed when there is already at least one trailer with the
- same <token> in the input.
+ same <key> in the input.
+
The valid values for this option are: `addIfDifferentNeighbor` (this
is the default), `addIfDifferent`, `add`, `replace` or `doNothing`.
+
With `addIfDifferentNeighbor`, a new trailer will be added only if no
-trailer with the same (<token>, <value>) pair is above or below the line
+trailer with the same (<key>, <value>) pair is above or below the line
where the new trailer will be added.
+
With `addIfDifferent`, a new trailer will be added only if no trailer
-with the same (<token>, <value>) pair is already in the input.
+with the same (<key>, <value>) pair is already in the input.
+
With `add`, a new trailer will be added, even if some trailers with
-the same (<token>, <value>) pair are already in the input.
+the same (<key>, <value>) pair are already in the input.
+
-With `replace`, an existing trailer with the same <token> will be
+With `replace`, an existing trailer with the same <key> will be
deleted and the new trailer will be added. The deleted trailer will be
-the closest one (with the same <token>) to the place where the new one
+the closest one (with the same <key>) to the place where the new one
will be added.
+
With `doNothing`, nothing will be done; that is no new trailer will be
-added if there is already one with the same <token> in the input.
+added if there is already one with the same <key> in the input.
trailer.ifmissing::
This option makes it possible to choose what action will be
performed when there is not yet any trailer with the same
- <token> in the input.
+ <key> in the input.
+
The valid values for this option are: `add` (this is the default) and
`doNothing`.
@@ -231,34 +258,40 @@ With `add`, a new trailer will be added.
+
With `doNothing`, nothing will be done.
-trailer.<token>.key::
- This `key` will be used instead of <token> in the trailer. At
- the end of this key, a separator can appear and then some
- space characters. By default the only valid separator is ':',
- but this can be changed using the `trailer.separators` config
- variable.
+trailer.<keyAlias>.key::
+ Defines a <keyAlias> for the <key>. The <keyAlias> must be a
+ prefix (case does not matter) of the <key>. For example, in `git
+ config trailer.ack.key "Acked-by"` the "Acked-by" is the <key> and
+ the "ack" is the <keyAlias>. This configuration allows the shorter
+ `--trailer "ack:..."` invocation on the command line using the "ack"
+ <keyAlias> instead of the longer `--trailer "Acked-by:..."`.
++
+At the end of the <key>, a separator can appear and then some
+space characters. By default the only valid separator is ':',
+but this can be changed using the `trailer.separators` config
+variable.
+
-If there is a separator, then the key will be used instead of both the
-<token> and the default separator when adding the trailer.
+If there is a separator in the key, then it overrides the default
+separator when adding the trailer.
-trailer.<token>.where::
+trailer.<keyAlias>.where::
This option takes the same values as the 'trailer.where'
configuration variable and it overrides what is specified by
- that option for trailers with the specified <token>.
+ that option for trailers with the specified <keyAlias>.
-trailer.<token>.ifexists::
+trailer.<keyAlias>.ifexists::
This option takes the same values as the 'trailer.ifexists'
configuration variable and it overrides what is specified by
- that option for trailers with the specified <token>.
+ that option for trailers with the specified <keyAlias>.
-trailer.<token>.ifmissing::
+trailer.<keyAlias>.ifmissing::
This option takes the same values as the 'trailer.ifmissing'
configuration variable and it overrides what is specified by
- that option for trailers with the specified <token>.
+ that option for trailers with the specified <keyAlias>.
-trailer.<token>.command::
- Deprecated in favor of 'trailer.<token>.cmd'.
- This option behaves in the same way as 'trailer.<token>.cmd', except
+trailer.<keyAlias>.command::
+ Deprecated in favor of 'trailer.<keyAlias>.cmd'.
+ This option behaves in the same way as 'trailer.<keyAlias>.cmd', except
that it doesn't pass anything as argument to the specified command.
Instead the first occurrence of substring $ARG is replaced by the
<value> that would be passed as argument.
@@ -266,29 +299,29 @@ trailer.<token>.command::
Note that $ARG in the user's command is
only replaced once and that the original way of replacing $ARG is not safe.
+
-When both 'trailer.<token>.cmd' and 'trailer.<token>.command' are given
-for the same <token>, 'trailer.<token>.cmd' is used and
-'trailer.<token>.command' is ignored.
+When both 'trailer.<keyAlias>.cmd' and 'trailer.<keyAlias>.command' are given
+for the same <keyAlias>, 'trailer.<keyAlias>.cmd' is used and
+'trailer.<keyAlias>.command' is ignored.
-trailer.<token>.cmd::
+trailer.<keyAlias>.cmd::
This option can be used to specify a shell command that will be called
- once to automatically add a trailer with the specified <token>, and then
- called each time a '--trailer <token>=<value>' argument is specified to
+ once to automatically add a trailer with the specified <keyAlias>, and then
+ called each time a '--trailer <keyAlias>=<value>' argument is specified to
modify the <value> of the trailer that this option would produce.
+
When the specified command is first called to add a trailer
-with the specified <token>, the behavior is as if a special
-'--trailer <token>=<value>' argument was added at the beginning
+with the specified <keyAlias>, the behavior is as if a special
+'--trailer <keyAlias>=<value>' argument was added at the beginning
of the "git interpret-trailers" command, where <value>
is taken to be the standard output of the command with any
leading and trailing whitespace trimmed off.
+
-If some '--trailer <token>=<value>' arguments are also passed
+If some '--trailer <keyAlias>=<value>' arguments are also passed
on the command line, the command is called again once for each
-of these arguments with the same <token>. And the <value> part
+of these arguments with the same <keyAlias>. And the <value> part
of these arguments, if any, will be passed to the command as its
first argument. This way the command can produce a <value> computed
-from the <value> passed in the '--trailer <token>=<value>' argument.
+from the <value> passed in the '--trailer <keyAlias>=<value>' argument.
EXAMPLES
--------
diff --git a/git-remote-helpers.html b/git-remote-helpers.html
index a30970634..5e0715426 100644
--- a/git-remote-helpers.html
+++ b/git-remote-helpers.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>git-remote-helpers</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div id="preamble">
diff --git a/howto/coordinate-embargoed-releases.html b/howto/coordinate-embargoed-releases.html
index 972713212..dd3e11652 100644
--- a/howto/coordinate-embargoed-releases.html
+++ b/howto/coordinate-embargoed-releases.html
@@ -1038,7 +1038,7 @@ Thanks,
<div id="footer">
<div id="footer-text">
Last updated
- 2023-10-12 13:23:57 PDT
+ 2023-10-13 15:25:56 PDT
</div>
</div>
</body>
diff --git a/howto/keep-canonical-history-correct.html b/howto/keep-canonical-history-correct.html
index ac88ff54d..25365746e 100644
--- a/howto/keep-canonical-history-correct.html
+++ b/howto/keep-canonical-history-correct.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>Keep authoritative canonical history correct with git pull</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div id="preamble">
@@ -939,7 +939,7 @@ tip of your <em>master</em> again and redo the two merges:</p></div>
<div id="footer">
<div id="footer-text">
Last updated
- 2023-10-12 13:23:57 PDT
+ 2023-10-13 15:25:55 PDT
</div>
</div>
</body>
diff --git a/howto/maintain-git.html b/howto/maintain-git.html
index fc23fad16..e8cd22939 100644
--- a/howto/maintain-git.html
+++ b/howto/maintain-git.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>How to maintain Git</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div class="sect1">
@@ -1479,7 +1479,7 @@ $ git update-ref -d $mf/ai/topic</code></pre>
<div id="footer">
<div id="footer-text">
Last updated
- 2023-10-12 13:23:57 PDT
+ 2023-10-13 15:25:56 PDT
</div>
</div>
</body>
diff --git a/howto/new-command.html b/howto/new-command.html
index 963734333..77935d479 100644
--- a/howto/new-command.html
+++ b/howto/new-command.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>How to integrate new subcommands</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div id="preamble">
@@ -864,7 +864,7 @@ letter [PATCH 0/n].
<div id="footer">
<div id="footer-text">
Last updated
- 2023-10-12 13:23:55 PDT
+ 2023-10-13 15:25:54 PDT
</div>
</div>
</body>
diff --git a/howto/rebase-from-internal-branch.html b/howto/rebase-from-internal-branch.html
index 19f67e156..22add2d3c 100644
--- a/howto/rebase-from-internal-branch.html
+++ b/howto/rebase-from-internal-branch.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>How to rebase from an internal branch</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div id="preamble">
@@ -896,7 +896,7 @@ the #1' commit.</p></div>
<div id="footer">
<div id="footer-text">
Last updated
- 2023-10-12 13:23:57 PDT
+ 2023-10-13 15:25:55 PDT
</div>
</div>
</body>
diff --git a/howto/rebuild-from-update-hook.html b/howto/rebuild-from-update-hook.html
index 6722ce873..025dbb08b 100644
--- a/howto/rebuild-from-update-hook.html
+++ b/howto/rebuild-from-update-hook.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>How to rebuild from update hook</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div id="preamble">
@@ -848,7 +848,7 @@ This is still crude and does not protect against simultaneous
<div id="footer">
<div id="footer-text">
Last updated
- 2023-10-12 13:23:57 PDT
+ 2023-10-13 15:25:55 PDT
</div>
</div>
</body>
diff --git a/howto/recover-corrupted-blob-object.html b/howto/recover-corrupted-blob-object.html
index 613af209a..6da67076d 100644
--- a/howto/recover-corrupted-blob-object.html
+++ b/howto/recover-corrupted-blob-object.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>How to recover a corrupted blob object</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div id="preamble">
@@ -881,7 +881,7 @@ thing.</p></div>
<div id="footer">
<div id="footer-text">
Last updated
- 2023-10-12 13:23:57 PDT
+ 2023-10-13 15:25:55 PDT
</div>
</div>
</body>
diff --git a/howto/recover-corrupted-object-harder.html b/howto/recover-corrupted-object-harder.html
index bcf64f9d4..14d2e2042 100644
--- a/howto/recover-corrupted-object-harder.html
+++ b/howto/recover-corrupted-object-harder.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>How to recover an object from scratch</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div id="preamble">
@@ -1190,7 +1190,7 @@ int main(int argc, char **argv)
<div id="footer">
<div id="footer-text">
Last updated
- 2023-10-12 13:23:57 PDT
+ 2023-10-13 15:25:55 PDT
</div>
</div>
</body>
diff --git a/howto/revert-a-faulty-merge.html b/howto/revert-a-faulty-merge.html
index 04512ac4c..025d2c98e 100644
--- a/howto/revert-a-faulty-merge.html
+++ b/howto/revert-a-faulty-merge.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>How to revert a faulty merge</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div id="preamble">
@@ -1026,7 +1026,7 @@ P---o---o---M---x---x---W---x---M2
<div id="footer">
<div id="footer-text">
Last updated
- 2023-10-12 13:23:57 PDT
+ 2023-10-13 15:25:55 PDT
</div>
</div>
</body>
diff --git a/howto/revert-branch-rebase.html b/howto/revert-branch-rebase.html
index 83656f9db..c675086f8 100644
--- a/howto/revert-branch-rebase.html
+++ b/howto/revert-branch-rebase.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>How to revert an existing commit</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div id="preamble">
@@ -908,7 +908,7 @@ Committed merge 7fb9b7262a1d1e0a47bbfdcbbcf50ce0635d3f8f
<div id="footer">
<div id="footer-text">
Last updated
- 2023-10-12 13:23:56 PDT
+ 2023-10-13 15:25:54 PDT
</div>
</div>
</body>
diff --git a/howto/separating-topic-branches.html b/howto/separating-topic-branches.html
index 837bd5a44..eae1dea93 100644
--- a/howto/separating-topic-branches.html
+++ b/howto/separating-topic-branches.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>How to separate topic branches</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div id="preamble">
@@ -842,7 +842,7 @@ o---o"master"</code></pre>
<div id="footer">
<div id="footer-text">
Last updated
- 2023-10-12 13:23:57 PDT
+ 2023-10-13 15:25:55 PDT
</div>
</div>
</body>
diff --git a/howto/setup-git-server-over-http.html b/howto/setup-git-server-over-http.html
index 803cabd79..6c7fa9bee 100644
--- a/howto/setup-git-server-over-http.html
+++ b/howto/setup-git-server-over-http.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>How to setup Git server over http</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div id="preamble">
@@ -1072,7 +1072,7 @@ help diagnosing the problem, but removes security checks.</p></div>
<div id="footer">
<div id="footer-text">
Last updated
- 2023-10-12 13:23:56 PDT
+ 2023-10-13 15:25:55 PDT
</div>
</div>
</body>
diff --git a/howto/update-hook-example.html b/howto/update-hook-example.html
index 5372512a9..23f693fe6 100644
--- a/howto/update-hook-example.html
+++ b/howto/update-hook-example.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>How to use the update hook</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div id="preamble">
@@ -931,7 +931,7 @@ that JC can make non-fast-forward pushes on it.</p></div>
<div id="footer">
<div id="footer-text">
Last updated
- 2023-10-12 13:23:56 PDT
+ 2023-10-13 15:25:55 PDT
</div>
</div>
</body>
diff --git a/howto/use-git-daemon.html b/howto/use-git-daemon.html
index 5f6c44e93..05b8065eb 100644
--- a/howto/use-git-daemon.html
+++ b/howto/use-git-daemon.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>How to use git-daemon</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div id="preamble">
@@ -792,7 +792,7 @@ a good practice to put the paths after a "--" separator.</p></div>
<div id="footer">
<div id="footer-text">
Last updated
- 2023-10-12 13:23:56 PDT
+ 2023-10-13 15:25:54 PDT
</div>
</div>
</body>
diff --git a/howto/using-merge-subtree.html b/howto/using-merge-subtree.html
index 8bc802656..ad88325f4 100644
--- a/howto/using-merge-subtree.html
+++ b/howto/using-merge-subtree.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>How to use the subtree merge strategy</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div id="preamble">
@@ -849,7 +849,7 @@ Please note that if the other project merges from you, then it will
<div id="footer">
<div id="footer-text">
Last updated
- 2023-10-12 13:23:56 PDT
+ 2023-10-13 15:25:54 PDT
</div>
</div>
</body>
diff --git a/howto/using-signed-tag-in-pull-request.html b/howto/using-signed-tag-in-pull-request.html
index f95353c34..5167c5ad7 100644
--- a/howto/using-signed-tag-in-pull-request.html
+++ b/howto/using-signed-tag-in-pull-request.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>How to use a signed tag in pull requests</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div id="preamble">
@@ -953,7 +953,7 @@ as part of the merge commit.</p></div>
<div id="footer">
<div id="footer-text">
Last updated
- 2023-10-12 13:23:56 PDT
+ 2023-10-13 15:25:54 PDT
</div>
</div>
</body>
diff --git a/technical/api-error-handling.html b/technical/api-error-handling.html
index 6912d3d8f..0e36339a3 100644
--- a/technical/api-error-handling.html
+++ b/technical/api-error-handling.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>Error reporting in git</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div id="preamble">
diff --git a/technical/api-index.html b/technical/api-index.html
index 2ac536bdf..e020c4254 100644
--- a/technical/api-index.html
+++ b/technical/api-index.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>Git API Documents</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div id="preamble">
diff --git a/technical/api-merge.html b/technical/api-merge.html
index 7b08e5b5c..d9b39bf01 100644
--- a/technical/api-merge.html
+++ b/technical/api-merge.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>merge API</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div id="preamble">
diff --git a/technical/api-parse-options.html b/technical/api-parse-options.html
index 130389aa6..e874e59fc 100644
--- a/technical/api-parse-options.html
+++ b/technical/api-parse-options.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>parse-options API</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div id="preamble">
diff --git a/technical/api-simple-ipc.html b/technical/api-simple-ipc.html
index a8f3731f6..486ca04f0 100644
--- a/technical/api-simple-ipc.html
+++ b/technical/api-simple-ipc.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>Simple-IPC API</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div id="preamble">
diff --git a/technical/api-trace2.html b/technical/api-trace2.html
index f9b74567c..3e9c1036b 100644
--- a/technical/api-trace2.html
+++ b/technical/api-trace2.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>Trace2 API</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div id="preamble">
diff --git a/technical/bitmap-format.html b/technical/bitmap-format.html
index a795c4634..91df4738d 100644
--- a/technical/bitmap-format.html
+++ b/technical/bitmap-format.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>GIT bitmap v1 format</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div class="sect1">
diff --git a/technical/bundle-uri.html b/technical/bundle-uri.html
index 99948aa27..c26ab469d 100644
--- a/technical/bundle-uri.html
+++ b/technical/bundle-uri.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>Bundle URIs</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div id="preamble">
diff --git a/technical/hash-function-transition.html b/technical/hash-function-transition.html
index a545124cc..4da56d95b 100644
--- a/technical/hash-function-transition.html
+++ b/technical/hash-function-transition.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>Git hash function transition</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div class="sect1">
diff --git a/technical/long-running-process-protocol.html b/technical/long-running-process-protocol.html
index 9d58f4f6f..2856fbee7 100644
--- a/technical/long-running-process-protocol.html
+++ b/technical/long-running-process-protocol.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>Long-running process protocol</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div id="preamble">
diff --git a/technical/multi-pack-index.html b/technical/multi-pack-index.html
index c0d60557e..590ac5cbd 100644
--- a/technical/multi-pack-index.html
+++ b/technical/multi-pack-index.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>Multi-Pack-Index (MIDX) Design Notes</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div id="preamble">
diff --git a/technical/pack-heuristics.html b/technical/pack-heuristics.html
index e3cf7fcc2..3cfd3cf02 100644
--- a/technical/pack-heuristics.html
+++ b/technical/pack-heuristics.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>Concerning Git&#8217;s Packing Heuristics</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div id="preamble">
diff --git a/technical/parallel-checkout.html b/technical/parallel-checkout.html
index 8e58ff097..e26a10daa 100644
--- a/technical/parallel-checkout.html
+++ b/technical/parallel-checkout.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>Parallel Checkout Design Notes</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div id="preamble">
diff --git a/technical/partial-clone.html b/technical/partial-clone.html
index ea5ac0d82..c0e929583 100644
--- a/technical/partial-clone.html
+++ b/technical/partial-clone.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>Partial Clone Design Notes</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div id="preamble">
diff --git a/technical/racy-git.html b/technical/racy-git.html
index c81aea599..a32034642 100644
--- a/technical/racy-git.html
+++ b/technical/racy-git.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>Use of index and Racy Git problem</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div class="sect1">
diff --git a/technical/scalar.html b/technical/scalar.html
index fe3b8f182..7d2ba8124 100644
--- a/technical/scalar.html
+++ b/technical/scalar.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>Scalar</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div id="preamble">
diff --git a/technical/send-pack-pipeline.html b/technical/send-pack-pipeline.html
index 80587b283..c5123534e 100644
--- a/technical/send-pack-pipeline.html
+++ b/technical/send-pack-pipeline.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>Git-send-pack internals</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div class="sect1">
diff --git a/technical/shallow.html b/technical/shallow.html
index 69154dd6e..f7d159dce 100644
--- a/technical/shallow.html
+++ b/technical/shallow.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>Shallow commits</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div id="preamble">
diff --git a/technical/trivial-merge.html b/technical/trivial-merge.html
index 8cc089cd5..3740d98b4 100644
--- a/technical/trivial-merge.html
+++ b/technical/trivial-merge.html
@@ -735,7 +735,7 @@ asciidoc.install();
<body class="article">
<div id="header">
<h1>Trivial merge rules</h1>
-<span id="revdate">2023-10-12</span>
+<span id="revdate">2023-10-13</span>
</div>
<div id="content">
<div id="preamble">
diff --git a/user-manual.html b/user-manual.html
index 17f721306..2e33868eb 100644
--- a/user-manual.html
+++ b/user-manual.html
@@ -1,5 +1,5 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
-<html><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"><title>Git User Manual</title><link rel="stylesheet" type="text/css" href="docbook-xsl.css"><meta name="generator" content="DocBook XSL Stylesheets Vsnapshot"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div lang="en" class="book"><div class="titlepage"><div><div><h1 class="title"><a name="id-1"></a>Git User Manual</h1></div><div><div class="revhistory"><table style="border-style:solid; width:100%;" summary="Revision History"><tr><th align="left" valign="top" colspan="2"><b>Revision History</b></th></tr><tr><td align="left"></td><td align="left">2023-10-12</td></tr></table></div></div></div><hr></div><div class="toc"><p><b>Table of Contents</b></p><dl class="toc"><dt><span class="preface"><a href="#_introduction">Introduction</a></span></dt><dt><span class="chapter"><a href="#repositories-and-branches">1. Repositories and Branches</a></span></dt><dd><dl><dt><span class="section"><a href="#how-to-get-a-git-repository">How to get a Git repository</a></span></dt><dt><span class="section"><a href="#how-to-check-out">How to check out a different version of a project</a></span></dt><dt><span class="section"><a href="#understanding-commits">Understanding History: Commits</a></span></dt><dd><dl><dt><span class="section"><a href="#understanding-reachability">Understanding history: commits, parents, and reachability</a></span></dt><dt><span class="section"><a href="#history-diagrams">Understanding history: History diagrams</a></span></dt><dt><span class="section"><a href="#what-is-a-branch">Understanding history: What is a branch?</a></span></dt></dl></dd><dt><span class="section"><a href="#manipulating-branches">Manipulating branches</a></span></dt><dt><span class="section"><a href="#detached-head">Examining an old version without creating a new branch</a></span></dt><dt><span class="section"><a href="#examining-remote-branches">Examining branches from a remote repository</a></span></dt><dt><span class="section"><a href="#how-git-stores-references">Naming branches, tags, and other references</a></span></dt><dt><span class="section"><a href="#Updating-a-repository-With-git-fetch">Updating a repository with git fetch</a></span></dt><dt><span class="section"><a href="#fetching-branches">Fetching branches from other repositories</a></span></dt></dl></dd><dt><span class="chapter"><a href="#exploring-git-history">2. Exploring Git history</a></span></dt><dd><dl><dt><span class="section"><a href="#using-bisect">How to use bisect to find a regression</a></span></dt><dt><span class="section"><a href="#naming-commits">Naming commits</a></span></dt><dt><span class="section"><a href="#creating-tags">Creating tags</a></span></dt><dt><span class="section"><a href="#browsing-revisions">Browsing revisions</a></span></dt><dt><span class="section"><a href="#generating-diffs">Generating diffs</a></span></dt><dt><span class="section"><a href="#viewing-old-file-versions">Viewing old file versions</a></span></dt><dt><span class="section"><a href="#history-examples">Examples</a></span></dt><dd><dl><dt><span class="section"><a href="#counting-commits-on-a-branch">Counting the number of commits on a branch</a></span></dt><dt><span class="section"><a href="#checking-for-equal-branches">Check whether two branches point at the same history</a></span></dt><dt><span class="section"><a href="#finding-tagged-descendants">Find first tagged version including a given fix</a></span></dt><dt><span class="section"><a href="#showing-commits-unique-to-a-branch">Showing commits unique to a given branch</a></span></dt><dt><span class="section"><a href="#making-a-release">Creating a changelog and tarball for a software release</a></span></dt><dt><span class="section"><a href="#Finding-commits-With-given-Content">Finding commits referencing a file with given content</a></span></dt></dl></dd></dl></dd><dt><span class="chapter"><a href="#Developing-With-git">3. Developing with Git</a></span></dt><dd><dl><dt><span class="section"><a href="#telling-git-your-name">Telling Git your name</a></span></dt><dt><span class="section"><a href="#creating-a-new-repository">Creating a new repository</a></span></dt><dt><span class="section"><a href="#how-to-make-a-commit">How to make a commit</a></span></dt><dt><span class="section"><a href="#creating-good-commit-messages">Creating good commit messages</a></span></dt><dt><span class="section"><a href="#ignoring-files">Ignoring files</a></span></dt><dt><span class="section"><a href="#how-to-merge">How to merge</a></span></dt><dt><span class="section"><a href="#resolving-a-merge">Resolving a merge</a></span></dt><dd><dl><dt><span class="section"><a href="#conflict-resolution">Getting conflict-resolution help during a merge</a></span></dt></dl></dd><dt><span class="section"><a href="#undoing-a-merge">Undoing a merge</a></span></dt><dt><span class="section"><a href="#fast-forwards">Fast-forward merges</a></span></dt><dt><span class="section"><a href="#fixing-mistakes">Fixing mistakes</a></span></dt><dd><dl><dt><span class="section"><a href="#reverting-a-commit">Fixing a mistake with a new commit</a></span></dt><dt><span class="section"><a href="#fixing-a-mistake-by-rewriting-history">Fixing a mistake by rewriting history</a></span></dt><dt><span class="section"><a href="#checkout-of-path">Checking out an old version of a file</a></span></dt><dt><span class="section"><a href="#interrupted-work">Temporarily setting aside work in progress</a></span></dt></dl></dd><dt><span class="section"><a href="#ensuring-good-performance">Ensuring good performance</a></span></dt><dt><span class="section"><a href="#ensuring-reliability">Ensuring reliability</a></span></dt><dd><dl><dt><span class="section"><a href="#checking-for-corruption">Checking the repository for corruption</a></span></dt><dt><span class="section"><a href="#recovering-lost-changes">Recovering lost changes</a></span></dt></dl></dd></dl></dd><dt><span class="chapter"><a href="#sharing-development">4. Sharing development with others</a></span></dt><dd><dl><dt><span class="section"><a href="#getting-updates-With-git-pull">Getting updates with git pull</a></span></dt><dt><span class="section"><a href="#submitting-patches">Submitting patches to a project</a></span></dt><dt><span class="section"><a href="#importing-patches">Importing patches to a project</a></span></dt><dt><span class="section"><a href="#public-repositories">Public Git repositories</a></span></dt><dd><dl><dt><span class="section"><a href="#setting-up-a-public-repository">Setting up a public repository</a></span></dt><dt><span class="section"><a href="#exporting-via-git">Exporting a Git repository via the Git protocol</a></span></dt><dt><span class="section"><a href="#exporting-via-http">Exporting a git repository via HTTP</a></span></dt><dt><span class="section"><a href="#pushing-changes-to-a-public-repository">Pushing changes to a public repository</a></span></dt><dt><span class="section"><a href="#forcing-push">What to do when a push fails</a></span></dt><dt><span class="section"><a href="#setting-up-a-shared-repository">Setting up a shared repository</a></span></dt><dt><span class="section"><a href="#setting-up-gitweb">Allowing web browsing of a repository</a></span></dt></dl></dd><dt><span class="section"><a href="#how-to-get-a-git-repository-with-minimal-history">How to get a Git repository with minimal history</a></span></dt><dt><span class="section"><a href="#sharing-development-examples">Examples</a></span></dt><dd><dl><dt><span class="section"><a href="#maintaining-topic-branches">Maintaining topic branches for a Linux subsystem maintainer</a></span></dt></dl></dd></dl></dd><dt><span class="chapter"><a href="#cleaning-up-history">5. Rewriting history and maintaining patch series</a></span></dt><dd><dl><dt><span class="section"><a href="#patch-series">Creating the perfect patch series</a></span></dt><dt><span class="section"><a href="#using-git-rebase">Keeping a patch series up to date using git rebase</a></span></dt><dt><span class="section"><a href="#rewriting-one-commit">Rewriting a single commit</a></span></dt><dt><span class="section"><a href="#reordering-patch-series">Reordering or selecting from a patch series</a></span></dt><dt><span class="section"><a href="#interactive-rebase">Using interactive rebases</a></span></dt><dt><span class="section"><a href="#patch-series-tools">Other tools</a></span></dt><dt><span class="section"><a href="#problems-With-rewriting-history">Problems with rewriting history</a></span></dt><dt><span class="section"><a href="#bisect-merges">Why bisecting merge commits can be harder than bisecting linear history</a></span></dt></dl></dd><dt><span class="chapter"><a href="#advanced-branch-management">6. Advanced branch management</a></span></dt><dd><dl><dt><span class="section"><a href="#fetching-individual-branches">Fetching individual branches</a></span></dt><dt><span class="section"><a href="#fetch-fast-forwards">git fetch and fast-forwards</a></span></dt><dt><span class="section"><a href="#forcing-fetch">Forcing git fetch to do non-fast-forward updates</a></span></dt><dt><span class="section"><a href="#remote-branch-configuration">Configuring remote-tracking branches</a></span></dt></dl></dd><dt><span class="chapter"><a href="#git-concepts">7. Git concepts</a></span></dt><dd><dl><dt><span class="section"><a href="#the-object-database">The Object Database</a></span></dt><dd><dl><dt><span class="section"><a href="#commit-object">Commit Object</a></span></dt><dt><span class="section"><a href="#tree-object">Tree Object</a></span></dt><dt><span class="section"><a href="#blob-object">Blob Object</a></span></dt><dt><span class="section"><a href="#trust">Trust</a></span></dt><dt><span class="section"><a href="#tag-object">Tag Object</a></span></dt><dt><span class="section"><a href="#pack-files">How Git stores objects efficiently: pack files</a></span></dt><dt><span class="section"><a href="#dangling-objects">Dangling objects</a></span></dt><dt><span class="section"><a href="#recovering-from-repository-corruption">Recovering from repository corruption</a></span></dt></dl></dd><dt><span class="section"><a href="#the-index">The index</a></span></dt></dl></dd><dt><span class="chapter"><a href="#submodules">8. Submodules</a></span></dt><dd><dl><dt><span class="section"><a href="#pitfalls-with-submodules">Pitfalls with submodules</a></span></dt></dl></dd><dt><span class="chapter"><a href="#low-level-operations">9. Low-level Git operations</a></span></dt><dd><dl><dt><span class="section"><a href="#object-manipulation">Object access and manipulation</a></span></dt><dt><span class="section"><a href="#the-workflow">The Workflow</a></span></dt><dd><dl><dt><span class="section"><a href="#working-directory-to-index">working directory → index</a></span></dt><dt><span class="section"><a href="#index-to-object-database">index → object database</a></span></dt><dt><span class="section"><a href="#object-database-to-index">object database → index</a></span></dt><dt><span class="section"><a href="#index-to-working-directory">index → working directory</a></span></dt><dt><span class="section"><a href="#tying-it-all-together">Tying it all together</a></span></dt></dl></dd><dt><span class="section"><a href="#examining-the-data">Examining the data</a></span></dt><dt><span class="section"><a href="#merging-multiple-trees">Merging multiple trees</a></span></dt><dt><span class="section"><a href="#merging-multiple-trees-2">Merging multiple trees, continued</a></span></dt></dl></dd><dt><span class="chapter"><a href="#hacking-git">10. Hacking Git</a></span></dt><dd><dl><dt><span class="section"><a href="#object-details">Object storage format</a></span></dt><dt><span class="section"><a href="#birdview-on-the-source-code">A birds-eye view of Git’s source code</a></span></dt></dl></dd><dt><span class="chapter"><a href="#glossary">11. Git Glossary</a></span></dt><dd><dl><dt><span class="section"><a href="#git-explained">Git explained</a></span></dt></dl></dd><dt><span class="appendix"><a href="#git-quick-start">A. Git Quick Reference</a></span></dt><dd><dl><dt><span class="section"><a href="#quick-creating-a-new-repository">Creating a new repository</a></span></dt><dt><span class="section"><a href="#managing-branches">Managing branches</a></span></dt><dt><span class="section"><a href="#exploring-history">Exploring history</a></span></dt><dt><span class="section"><a href="#making-changes">Making changes</a></span></dt><dt><span class="section"><a href="#merging">Merging</a></span></dt><dt><span class="section"><a href="#sharing-your-changes">Sharing your changes</a></span></dt><dt><span class="section"><a href="#repository-maintenance">Repository maintenance</a></span></dt></dl></dd><dt><span class="appendix"><a href="#todo">B. Notes and todo list for this manual</a></span></dt><dd><dl><dt><span class="section"><a href="#todo-list">Todo list</a></span></dt></dl></dd></dl></div><div class="preface"><div class="titlepage"><div><div><h1 class="title"><a name="_introduction"></a>Introduction</h1></div></div></div><p>Git is a fast distributed revision control system.</p><p>This manual is designed to be readable by someone with basic UNIX
+<html><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"><title>Git User Manual</title><link rel="stylesheet" type="text/css" href="docbook-xsl.css"><meta name="generator" content="DocBook XSL Stylesheets Vsnapshot"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div lang="en" class="book"><div class="titlepage"><div><div><h1 class="title"><a name="id-1"></a>Git User Manual</h1></div><div><div class="revhistory"><table style="border-style:solid; width:100%;" summary="Revision History"><tr><th align="left" valign="top" colspan="2"><b>Revision History</b></th></tr><tr><td align="left"></td><td align="left">2023-10-13</td></tr></table></div></div></div><hr></div><div class="toc"><p><b>Table of Contents</b></p><dl class="toc"><dt><span class="preface"><a href="#_introduction">Introduction</a></span></dt><dt><span class="chapter"><a href="#repositories-and-branches">1. Repositories and Branches</a></span></dt><dd><dl><dt><span class="section"><a href="#how-to-get-a-git-repository">How to get a Git repository</a></span></dt><dt><span class="section"><a href="#how-to-check-out">How to check out a different version of a project</a></span></dt><dt><span class="section"><a href="#understanding-commits">Understanding History: Commits</a></span></dt><dd><dl><dt><span class="section"><a href="#understanding-reachability">Understanding history: commits, parents, and reachability</a></span></dt><dt><span class="section"><a href="#history-diagrams">Understanding history: History diagrams</a></span></dt><dt><span class="section"><a href="#what-is-a-branch">Understanding history: What is a branch?</a></span></dt></dl></dd><dt><span class="section"><a href="#manipulating-branches">Manipulating branches</a></span></dt><dt><span class="section"><a href="#detached-head">Examining an old version without creating a new branch</a></span></dt><dt><span class="section"><a href="#examining-remote-branches">Examining branches from a remote repository</a></span></dt><dt><span class="section"><a href="#how-git-stores-references">Naming branches, tags, and other references</a></span></dt><dt><span class="section"><a href="#Updating-a-repository-With-git-fetch">Updating a repository with git fetch</a></span></dt><dt><span class="section"><a href="#fetching-branches">Fetching branches from other repositories</a></span></dt></dl></dd><dt><span class="chapter"><a href="#exploring-git-history">2. Exploring Git history</a></span></dt><dd><dl><dt><span class="section"><a href="#using-bisect">How to use bisect to find a regression</a></span></dt><dt><span class="section"><a href="#naming-commits">Naming commits</a></span></dt><dt><span class="section"><a href="#creating-tags">Creating tags</a></span></dt><dt><span class="section"><a href="#browsing-revisions">Browsing revisions</a></span></dt><dt><span class="section"><a href="#generating-diffs">Generating diffs</a></span></dt><dt><span class="section"><a href="#viewing-old-file-versions">Viewing old file versions</a></span></dt><dt><span class="section"><a href="#history-examples">Examples</a></span></dt><dd><dl><dt><span class="section"><a href="#counting-commits-on-a-branch">Counting the number of commits on a branch</a></span></dt><dt><span class="section"><a href="#checking-for-equal-branches">Check whether two branches point at the same history</a></span></dt><dt><span class="section"><a href="#finding-tagged-descendants">Find first tagged version including a given fix</a></span></dt><dt><span class="section"><a href="#showing-commits-unique-to-a-branch">Showing commits unique to a given branch</a></span></dt><dt><span class="section"><a href="#making-a-release">Creating a changelog and tarball for a software release</a></span></dt><dt><span class="section"><a href="#Finding-commits-With-given-Content">Finding commits referencing a file with given content</a></span></dt></dl></dd></dl></dd><dt><span class="chapter"><a href="#Developing-With-git">3. Developing with Git</a></span></dt><dd><dl><dt><span class="section"><a href="#telling-git-your-name">Telling Git your name</a></span></dt><dt><span class="section"><a href="#creating-a-new-repository">Creating a new repository</a></span></dt><dt><span class="section"><a href="#how-to-make-a-commit">How to make a commit</a></span></dt><dt><span class="section"><a href="#creating-good-commit-messages">Creating good commit messages</a></span></dt><dt><span class="section"><a href="#ignoring-files">Ignoring files</a></span></dt><dt><span class="section"><a href="#how-to-merge">How to merge</a></span></dt><dt><span class="section"><a href="#resolving-a-merge">Resolving a merge</a></span></dt><dd><dl><dt><span class="section"><a href="#conflict-resolution">Getting conflict-resolution help during a merge</a></span></dt></dl></dd><dt><span class="section"><a href="#undoing-a-merge">Undoing a merge</a></span></dt><dt><span class="section"><a href="#fast-forwards">Fast-forward merges</a></span></dt><dt><span class="section"><a href="#fixing-mistakes">Fixing mistakes</a></span></dt><dd><dl><dt><span class="section"><a href="#reverting-a-commit">Fixing a mistake with a new commit</a></span></dt><dt><span class="section"><a href="#fixing-a-mistake-by-rewriting-history">Fixing a mistake by rewriting history</a></span></dt><dt><span class="section"><a href="#checkout-of-path">Checking out an old version of a file</a></span></dt><dt><span class="section"><a href="#interrupted-work">Temporarily setting aside work in progress</a></span></dt></dl></dd><dt><span class="section"><a href="#ensuring-good-performance">Ensuring good performance</a></span></dt><dt><span class="section"><a href="#ensuring-reliability">Ensuring reliability</a></span></dt><dd><dl><dt><span class="section"><a href="#checking-for-corruption">Checking the repository for corruption</a></span></dt><dt><span class="section"><a href="#recovering-lost-changes">Recovering lost changes</a></span></dt></dl></dd></dl></dd><dt><span class="chapter"><a href="#sharing-development">4. Sharing development with others</a></span></dt><dd><dl><dt><span class="section"><a href="#getting-updates-With-git-pull">Getting updates with git pull</a></span></dt><dt><span class="section"><a href="#submitting-patches">Submitting patches to a project</a></span></dt><dt><span class="section"><a href="#importing-patches">Importing patches to a project</a></span></dt><dt><span class="section"><a href="#public-repositories">Public Git repositories</a></span></dt><dd><dl><dt><span class="section"><a href="#setting-up-a-public-repository">Setting up a public repository</a></span></dt><dt><span class="section"><a href="#exporting-via-git">Exporting a Git repository via the Git protocol</a></span></dt><dt><span class="section"><a href="#exporting-via-http">Exporting a git repository via HTTP</a></span></dt><dt><span class="section"><a href="#pushing-changes-to-a-public-repository">Pushing changes to a public repository</a></span></dt><dt><span class="section"><a href="#forcing-push">What to do when a push fails</a></span></dt><dt><span class="section"><a href="#setting-up-a-shared-repository">Setting up a shared repository</a></span></dt><dt><span class="section"><a href="#setting-up-gitweb">Allowing web browsing of a repository</a></span></dt></dl></dd><dt><span class="section"><a href="#how-to-get-a-git-repository-with-minimal-history">How to get a Git repository with minimal history</a></span></dt><dt><span class="section"><a href="#sharing-development-examples">Examples</a></span></dt><dd><dl><dt><span class="section"><a href="#maintaining-topic-branches">Maintaining topic branches for a Linux subsystem maintainer</a></span></dt></dl></dd></dl></dd><dt><span class="chapter"><a href="#cleaning-up-history">5. Rewriting history and maintaining patch series</a></span></dt><dd><dl><dt><span class="section"><a href="#patch-series">Creating the perfect patch series</a></span></dt><dt><span class="section"><a href="#using-git-rebase">Keeping a patch series up to date using git rebase</a></span></dt><dt><span class="section"><a href="#rewriting-one-commit">Rewriting a single commit</a></span></dt><dt><span class="section"><a href="#reordering-patch-series">Reordering or selecting from a patch series</a></span></dt><dt><span class="section"><a href="#interactive-rebase">Using interactive rebases</a></span></dt><dt><span class="section"><a href="#patch-series-tools">Other tools</a></span></dt><dt><span class="section"><a href="#problems-With-rewriting-history">Problems with rewriting history</a></span></dt><dt><span class="section"><a href="#bisect-merges">Why bisecting merge commits can be harder than bisecting linear history</a></span></dt></dl></dd><dt><span class="chapter"><a href="#advanced-branch-management">6. Advanced branch management</a></span></dt><dd><dl><dt><span class="section"><a href="#fetching-individual-branches">Fetching individual branches</a></span></dt><dt><span class="section"><a href="#fetch-fast-forwards">git fetch and fast-forwards</a></span></dt><dt><span class="section"><a href="#forcing-fetch">Forcing git fetch to do non-fast-forward updates</a></span></dt><dt><span class="section"><a href="#remote-branch-configuration">Configuring remote-tracking branches</a></span></dt></dl></dd><dt><span class="chapter"><a href="#git-concepts">7. Git concepts</a></span></dt><dd><dl><dt><span class="section"><a href="#the-object-database">The Object Database</a></span></dt><dd><dl><dt><span class="section"><a href="#commit-object">Commit Object</a></span></dt><dt><span class="section"><a href="#tree-object">Tree Object</a></span></dt><dt><span class="section"><a href="#blob-object">Blob Object</a></span></dt><dt><span class="section"><a href="#trust">Trust</a></span></dt><dt><span class="section"><a href="#tag-object">Tag Object</a></span></dt><dt><span class="section"><a href="#pack-files">How Git stores objects efficiently: pack files</a></span></dt><dt><span class="section"><a href="#dangling-objects">Dangling objects</a></span></dt><dt><span class="section"><a href="#recovering-from-repository-corruption">Recovering from repository corruption</a></span></dt></dl></dd><dt><span class="section"><a href="#the-index">The index</a></span></dt></dl></dd><dt><span class="chapter"><a href="#submodules">8. Submodules</a></span></dt><dd><dl><dt><span class="section"><a href="#pitfalls-with-submodules">Pitfalls with submodules</a></span></dt></dl></dd><dt><span class="chapter"><a href="#low-level-operations">9. Low-level Git operations</a></span></dt><dd><dl><dt><span class="section"><a href="#object-manipulation">Object access and manipulation</a></span></dt><dt><span class="section"><a href="#the-workflow">The Workflow</a></span></dt><dd><dl><dt><span class="section"><a href="#working-directory-to-index">working directory → index</a></span></dt><dt><span class="section"><a href="#index-to-object-database">index → object database</a></span></dt><dt><span class="section"><a href="#object-database-to-index">object database → index</a></span></dt><dt><span class="section"><a href="#index-to-working-directory">index → working directory</a></span></dt><dt><span class="section"><a href="#tying-it-all-together">Tying it all together</a></span></dt></dl></dd><dt><span class="section"><a href="#examining-the-data">Examining the data</a></span></dt><dt><span class="section"><a href="#merging-multiple-trees">Merging multiple trees</a></span></dt><dt><span class="section"><a href="#merging-multiple-trees-2">Merging multiple trees, continued</a></span></dt></dl></dd><dt><span class="chapter"><a href="#hacking-git">10. Hacking Git</a></span></dt><dd><dl><dt><span class="section"><a href="#object-details">Object storage format</a></span></dt><dt><span class="section"><a href="#birdview-on-the-source-code">A birds-eye view of Git’s source code</a></span></dt></dl></dd><dt><span class="chapter"><a href="#glossary">11. Git Glossary</a></span></dt><dd><dl><dt><span class="section"><a href="#git-explained">Git explained</a></span></dt></dl></dd><dt><span class="appendix"><a href="#git-quick-start">A. Git Quick Reference</a></span></dt><dd><dl><dt><span class="section"><a href="#quick-creating-a-new-repository">Creating a new repository</a></span></dt><dt><span class="section"><a href="#managing-branches">Managing branches</a></span></dt><dt><span class="section"><a href="#exploring-history">Exploring history</a></span></dt><dt><span class="section"><a href="#making-changes">Making changes</a></span></dt><dt><span class="section"><a href="#merging">Merging</a></span></dt><dt><span class="section"><a href="#sharing-your-changes">Sharing your changes</a></span></dt><dt><span class="section"><a href="#repository-maintenance">Repository maintenance</a></span></dt></dl></dd><dt><span class="appendix"><a href="#todo">B. Notes and todo list for this manual</a></span></dt><dd><dl><dt><span class="section"><a href="#todo-list">Todo list</a></span></dt></dl></dd></dl></div><div class="preface"><div class="titlepage"><div><div><h1 class="title"><a name="_introduction"></a>Introduction</h1></div></div></div><p>Git is a fast distributed revision control system.</p><p>This manual is designed to be readable by someone with basic UNIX
command-line skills, but no previous knowledge of Git.</p><p><a class="xref" href="#repositories-and-branches" title="Chapter 1. Repositories and Branches">Chapter 1, <i>Repositories and Branches</i></a> and <a class="xref" href="#exploring-git-history" title="Chapter 2. Exploring Git history">Chapter 2, <i>Exploring Git history</i></a> explain how
to fetch and study a project using git—read these chapters to learn how
to build and test a particular version of a software project, search for