<feed xmlns='http://www.w3.org/2005/Atom'>
<title>git/Documentation/git.txt, branch v2.48.2</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/git/git.git/
</subtitle>
<id>https://git.shady.money/git/atom?h=v2.48.2</id>
<link rel='self' href='https://git.shady.money/git/atom?h=v2.48.2'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/'/>
<updated>2025-01-06T16:23:29Z</updated>
<entry>
<title>Merge branch 'mh/doc-windows-home-env'</title>
<updated>2025-01-06T16:23:29Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2025-01-06T16:23:29Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=1fa37a06082584d4087937467ad3f3b0f0f31905'/>
<id>urn:sha1:1fa37a06082584d4087937467ad3f3b0f0f31905</id>
<content type='text'>
Docfix.

* mh/doc-windows-home-env:
  git.txt: fix heading line of tildes
</content>
</entry>
<entry>
<title>git.txt: fix heading line of tildes</title>
<updated>2025-01-03T16:23:10Z</updated>
<author>
<name>Martin Ågren</name>
<email>martin.agren@gmail.com</email>
</author>
<published>2025-01-03T11:33:30Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=38d7016891e37a789d389eddc7cd3dc9b76370b4'/>
<id>urn:sha1:38d7016891e37a789d389eddc7cd3dc9b76370b4</id>
<content type='text'>
The two-line heading added in 8525e92886 (Document HOME environment
variable, 2024-12-09) uses too many tilde characters, so the heading
isn't detected as such. Both AsciiDoc and Asciidoctor end up
misrendering this in different ways.

Use the correct number of tilde characters to fix this.

Signed-off-by: Martin Ågren &lt;martin.agren@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'mh/doc-windows-home-env'</title>
<updated>2024-12-19T18:58:32Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2024-12-19T18:58:32Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=930f2b48118e13e4f74ed709f2708d0d863d420e'/>
<id>urn:sha1:930f2b48118e13e4f74ed709f2708d0d863d420e</id>
<content type='text'>
Doc update.

* mh/doc-windows-home-env:
  Document HOME environment variable
</content>
</entry>
<entry>
<title>Document HOME environment variable</title>
<updated>2024-12-09T23:47:55Z</updated>
<author>
<name>Alejandro Barreto</name>
<email>alejandro.barreto@ni.com</email>
</author>
<published>2024-12-09T19:18:14Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=8525e928868757c2ebce3859dae0a9fd0f9ac9fd'/>
<id>urn:sha1:8525e928868757c2ebce3859dae0a9fd0f9ac9fd</id>
<content type='text'>
Git documentation refers to $HOME and $XDG_CONFIG_HOME often, but does
not specify how or where these values come from on Windows where neither
is set by default. The new documentation reflects the behavior of
setup_windows_environment() in compat/mingw.c.

Signed-off-by: Alejandro Barreto &lt;alejandro.barreto@ni.com&gt;
Signed-off-by: M Hickford &lt;mirth.hickford@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Documentation: allow sourcing generated includes from separate dir</title>
<updated>2024-12-06T22:52:12Z</updated>
<author>
<name>Patrick Steinhardt</name>
<email>ps@pks.im</email>
</author>
<published>2024-12-06T13:24:53Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=9219325be74c35c493a61ab3107d215cad91cf38'/>
<id>urn:sha1:9219325be74c35c493a61ab3107d215cad91cf38</id>
<content type='text'>
Our documentation uses "include::" directives to include parts that are
either reused across multiple documents or parts that we generate at
build time. Unfortunately, top-level includes are only ever resolved
relative to the base directory, which is typically the directory of the
including document. Most importantly, it is not possible to have either
asciidoc or asciidoctor search multiple directories.

It follows that both kinds of includes must live in the same directory.
This is of course a bummer for out-of-tree builds, because here the
dynamically-built includes live in the build directory whereas the
static includes live in the source directory.

Introduce a `build_dir` attribute and prepend it to all of our includes
for dynamically-built files. This attribute gets set to the build
directory and thus converts the include path to an absolute path, which
asciidoc and asciidoctor know how to resolve.

Note that this change also requires us to update "build-docdep.perl",
which tries to figure out included files such our Makefile can set up
proper build-time dependencies. This script simply scans through the
source files for any lines that match "^include::" and treats the
remainder of the line as included file path. But given that those may
now contain the "{build_dir}" variable we have to teach the script to
replace that attribute with the actual build directory.

Signed-off-by: Patrick Steinhardt &lt;ps@pks.im&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>advice: recommend GIT_ADVICE=0 for tools</title>
<updated>2024-09-06T21:15:16Z</updated>
<author>
<name>Derrick Stolee</name>
<email>stolee@gmail.com</email>
</author>
<published>2024-09-06T20:22:35Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=fb2b9815a4b5ea04a5f08940f546c6d5ef5e2414'/>
<id>urn:sha1:fb2b9815a4b5ea04a5f08940f546c6d5ef5e2414</id>
<content type='text'>
The GIT_ADVICE environment variable was added implicitly in b79deeb5544
(advice: add --no-advice global option, 2024-05-03) but was not
documented. Add documentation to show that it is an option for tools
that want to disable these messages. Make note that while the
--no-advice option exists, older Git versions will fail to parse that
option. The environment variable presents a way to change the behavior
of Git versions that understand it without disrupting older versions.

Co-authored-by: Junio C Hamano &lt;gitster@pobox.com&gt;
Signed-off-by: Derrick Stolee &lt;stolee@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>diff: let external diffs report that changes are uninteresting</title>
<updated>2024-06-10T16:20:46Z</updated>
<author>
<name>René Scharfe</name>
<email>l.s.r@web.de</email>
</author>
<published>2024-06-09T07:41:44Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=d7b97b7185521e3b9364b3abc6553df2480da173'/>
<id>urn:sha1:d7b97b7185521e3b9364b3abc6553df2480da173</id>
<content type='text'>
The options --exit-code and --quiet instruct git diff to indicate
whether it found any significant changes by exiting with code 1 if it
did and 0 if there were none.  Currently this doesn't work if external
diff programs are involved, as we have no way to learn what they found.

Add that ability in the form of the new configuration options
diff.trustExitCode and diff.&lt;driver&gt;.trustExitCode and the environment
variable GIT_EXTERNAL_DIFF_TRUST_EXIT_CODE.  They pair with the config
options diff.external and diff.&lt;driver&gt;.command and the environment
variable GIT_EXTERNAL_DIFF, respectively.

The new options are off by default, keeping the old behavior.  Enabling
them indicates that the external diff returns exit code 1 if it finds
significant changes and 0 if it doesn't, like diff(1).

The name of the new options is taken from the git difftool and mergetool
options of similar purpose.  (There they enable passing on the exit code
of a diff tool and to infer whether a merge done by a merge tool is
successful.)

The new feature sets the diff flag diff_from_contents in
diff_setup_done() if we need the exit code and are allowed to call
external diffs.  This disables the optimization that avoids calling the
program with --quiet.  Add it back by skipping the call if the external
diff is not able to report empty diffs.  We can only do that check after
evaluating the file-specific attributes in run_external_diff().

If we do run the external diff with --quiet, send its output to
/dev/null.

I considered checking the output of the external diff to check whether
its empty.  It was added as 11be65cfa4 (diff: fix --exit-code with
external diff, 2024-05-05) and quickly reverted, as it does not work
with external diffs that do not write to stdout.  There's no reason why
a graphical diff tool would even need to write anything there at all.

I also considered using a non-zero exit code for empty diffs, which
could be done without adding new configuration options.  We'd need to
disable the optimization that allows git diff --quiet to skip calling
external diffs, though -- that might be quite surprising if graphical
diff programs are involved.  And assigning the opposite meaning of the
exit codes compared to diff(1) and git diff --exit-code to the external
diff can cause unnecessary confusion.

Suggested-by: Phillip Wood &lt;phillip.wood123@gmail.com&gt;
Signed-off-by: René Scharfe &lt;l.s.r@web.de&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'jl/git-no-advice'</title>
<updated>2024-05-16T17:10:13Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2024-05-16T17:10:13Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=f0e2183768b1548bcaea9e311bb5a54112c0a9f4'/>
<id>urn:sha1:f0e2183768b1548bcaea9e311bb5a54112c0a9f4</id>
<content type='text'>
A new global "--no-advice" option can be used to disable all advice
messages, which is meant to be used only in scripts.

* jl/git-no-advice:
  t0018: two small fixes
  advice: add --no-advice global option
  doc: add spacing around paginate options
  doc: clean up usage documentation for --no-* opts
</content>
</entry>
<entry>
<title>advice: add --no-advice global option</title>
<updated>2024-05-03T17:36:59Z</updated>
<author>
<name>James Liu</name>
<email>james@jamesliu.io</email>
</author>
<published>2024-05-03T07:17:06Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=b79deeb55444f9e01a3f6335d7e0507e23e90190'/>
<id>urn:sha1:b79deeb55444f9e01a3f6335d7e0507e23e90190</id>
<content type='text'>
Advice hints must be disabled individually by setting the relevant
advice.* variables to false in the Git configuration. For server-side
and scripted usages of Git where hints can be a hindrance, it can be
cumbersome to maintain configuration to ensure all advice hints are
disabled in perpetuity. This is a particular concern in tests, where
new or changed hints can result in failed assertions.

Add a --no-advice global option to disable all advice hints from being
displayed. This is independent of the toggles for individual advice
hints. Use an internal environment variable (GIT_ADVICE) to ensure this
configuration is propagated to the usage site, even if it executes in a
subprocess.

Signed-off-by: James Liu &lt;james@jamesliu.io&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>doc: add spacing around paginate options</title>
<updated>2024-05-03T17:33:12Z</updated>
<author>
<name>James Liu</name>
<email>james@jamesliu.io</email>
</author>
<published>2024-05-03T07:17:05Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=5bd8811a734536186dd69ae767a9d58ce01ad7cb'/>
<id>urn:sha1:5bd8811a734536186dd69ae767a9d58ce01ad7cb</id>
<content type='text'>
Make the documentation page consistent with the usage string printed by
"git help git" and consistent with the description of "[-v | --version]"
option.

Signed-off-by: James Liu &lt;james@jamesliu.io&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
</feed>
