git/Documentation/config
Patrick Steinhardt 9219325be7 Documentation: allow sourcing generated includes from separate dir
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 <ps@pks.im>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2024-12-07 07:52:12 +09:00
..
add.txt doc: git-add.txt: convert to new style convention 2024-11-12 09:32:18 +09:00
advice.txt advice: recommend GIT_ADVICE=0 for tools 2024-09-06 14:15:16 -07:00
alias.txt Documentation: alias: add notes on shell expansion 2024-05-31 15:47:55 -07:00
am.txt
apply.txt documentation: whitespace is already generally plural 2023-10-09 12:06:29 -07:00
attr.txt attr.tree: HEAD:.gitattributes is no longer the default in a bare repo 2024-06-05 14:52:53 -07:00
bitmap-pseudo-merge.txt pseudo-merge: implement support for selecting pseudo-merge commits 2024-05-24 11:40:42 -07:00
blame.txt
branch.txt documentation: use clearer prepositions 2023-10-09 12:06:29 -07:00
browser.txt
bundle.txt
checkout.txt documentation: fix capitalization 2023-10-09 12:06:29 -07:00
clean.txt clean: further clean-up of implementation around "--force" 2024-03-04 14:05:13 -08:00
clone.txt doc: git-clone: do not autoreference the manpage in itself 2024-03-29 10:57:41 -07:00
color.txt documentation: add some commas where they are helpful 2023-10-09 12:06:44 -07:00
column.txt documentation: fix singular vs. plural 2023-10-09 12:06:29 -07:00
commit.txt documentation: add missing article 2023-10-09 12:06:29 -07:00
commitgraph.txt commit-graph: new Bloom filter version that fixes murmur3 2024-06-25 13:52:06 -07:00
completion.txt
core.txt doc: consolidate extensions in git-config documentation 2024-10-22 12:49:32 -04:00
credential.txt credential: add new interactive config option 2024-09-20 14:44:31 -07:00
diff.txt Documentation: allow sourcing generated includes from separate dir 2024-12-07 07:52:12 +09:00
difftool.txt mergetool: new config guiDefault supports auto-toggling gui by DISPLAY 2023-04-05 21:03:29 -07:00
extensions.txt doc: consolidate extensions in git-config documentation 2024-10-22 12:49:32 -04:00
fastimport.txt documentation: add some commas where they are helpful 2023-10-09 12:06:44 -07:00
feature.txt pack-objects: enable multi-pack reuse via `feature.experimental` 2024-02-05 15:27:01 -08:00
fetch.txt fetch: add new config option fetch.all 2024-01-08 13:36:23 -08:00
filter.txt
fmt-merge-msg.txt
format.txt Merge branch 'jc/doc-misspelt-refs-fix' into maint-2.43 2024-02-08 16:22:08 -08:00
fsck.txt documentation: add some commas where they are helpful 2023-10-09 12:06:44 -07:00
fsmonitor--daemon.txt documentation: wording improvements 2023-10-09 12:04:21 -07:00
gc.txt Documentation/config: fix typos 2024-09-23 12:46:59 -07:00
gitcvs.txt
gitweb.txt
gpg.txt documentation: fix subject/verb agreement 2023-10-09 12:06:29 -07:00
grep.txt grep docs: describe --recurse-submodules further and improve formatting a bit 2024-03-25 14:00:03 -07:00
gui.txt documentation: add missing article 2023-10-09 12:06:29 -07:00
guitool.txt
help.txt
http.txt http: do not ignore proxy path 2024-08-02 08:30:08 -07:00
i18n.txt documentation: use clearer prepositions 2023-10-09 12:06:29 -07:00
imap.txt documentation: fix verb vs. noun 2023-10-09 12:06:29 -07:00
includeif.txt
index.txt documentation: fix apostrophe usage 2023-10-09 12:06:29 -07:00
init.txt setup: make ref storage format configurable via config 2024-08-16 09:55:22 -07:00
instaweb.txt
interactive.txt doc: interactive.singleKey is disabled by default 2024-06-07 15:27:41 -07:00
log.txt documentation: add some commas where they are helpful 2023-10-09 12:06:44 -07:00
lsrefs.txt
mailinfo.txt documentation: fix singular vs. plural 2023-10-09 12:06:29 -07:00
mailmap.txt
maintenance.txt run-command: fix detaching when running auto maintenance 2024-08-16 09:46:26 -07:00
man.txt documentation: add missing article 2023-10-09 12:06:29 -07:00
merge.txt Documentation: allow sourcing generated includes from separate dir 2024-12-07 07:52:12 +09:00
mergetool.txt mergetools: vimdiff: use correct tool's name when reading mergetool config 2024-02-19 08:45:14 -08:00
notes.txt documentation: add missing article 2023-10-09 12:06:29 -07:00
pack.txt Documentation/config/pack.txt: fix broken AsciiDoc mark-up 2024-02-23 13:47:16 -08:00
pager.txt
pretty.txt
promisor.txt promisor-remote: add promisor.quiet configuration option 2024-05-26 09:17:08 -07:00
protocol.txt
pull.txt
push.txt documentation: add some commas where they are helpful 2023-10-09 12:06:44 -07:00
rebase.txt Merge branch 'ms/rebase-insnformat-doc-fix' into maint-2.43 2024-02-08 16:22:12 -08:00
receive.txt builtin/receive-pack: convert to use git-maintenance(1) 2024-04-17 08:42:26 -07:00
reftable.txt refs/reftable: introduce "reftable.lockTimeout" 2024-09-24 09:45:25 -07:00
remote.txt remote: introduce remote.<name>.serverOption configuration 2024-10-08 10:22:07 -07:00
remotes.txt
repack.txt
rerere.txt documentation: fix singular vs. plural 2023-10-09 12:06:29 -07:00
revert.txt
safe.txt safe.directory: allow "lead/ing/path/*" match 2024-05-29 12:06:27 -07:00
sendemail.txt send-email: document --mailmap and associated configuration 2024-09-25 08:58:38 -07:00
sequencer.txt documentation: add some commas where they are helpful 2023-10-09 12:06:44 -07:00
showbranch.txt
sparse.txt
splitindex.txt documentation: add some commas where they are helpful 2023-10-09 12:06:44 -07:00
ssh.txt
stash.txt documentation: add missing article 2023-10-09 12:06:29 -07:00
status.txt status: allow --untracked=false and friends 2024-03-13 10:43:32 -07:00
submodule.txt documentation: fix apostrophe usage 2023-10-09 12:06:29 -07:00
tag.txt
tar.txt
trace2.txt documentation: wording improvements 2023-10-09 12:04:21 -07:00
transfer.txt upload-pack: disallow object-info capability by default 2024-02-28 14:42:01 -08:00
uploadarchive.txt
uploadpack.txt doc: document how uploadpack.allowAnySHA1InWant impact other allow options 2024-10-21 15:49:35 -04:00
url.txt
user.txt documentation: add some commas where they are helpful 2023-10-09 12:06:44 -07:00
versionsort.txt documentation: add some commas where they are helpful 2023-10-09 12:06:44 -07:00
web.txt
worktree.txt