]> git.ipfire.org Git - thirdparty/git.git/commit
daemon: clarify directory arguments
authorDerrick Stolee <derrickstolee@github.com>
Tue, 19 Jul 2022 18:32:13 +0000 (18:32 +0000)
committerJunio C Hamano <gitster@pobox.com>
Tue, 19 Jul 2022 19:45:31 +0000 (12:45 -0700)
commitdee8a1455c8ad443ef59e0d5b7c168886e50b9ea
treee305a21944fd0d245d3d9c7eb8b4b8ef79d29943
parente4a4b31577c7419497ac30cebe30d755b97752c5
daemon: clarify directory arguments

The undecorated arguments to the 'git-daemon' command provide a list of
directories. When at least one directory is specified, then 'git-daemon'
only serves requests that are within that directory list. The boolean
'--strict-paths' option makes the list more explicit in that
subdirectories are no longer included.

The existing documentation and error messages around this directory list
refer to it and its behavior as a "whitelist". The word "whitelist" has
cultural implications that are not inclusive.  Thankfully, it is not
difficult to reword and avoid its use. In the process, we can define the
purpose of this directory list directly.

In Documentation/git-daemon.txt, rewrite the OPTIONS section around the
'<directory>' option. Add additional clarity to the other options that
refer to these directories.

Some error messages can also be improved in daemon.c. The
'--strict-paths' option requires '<directory>' arguments, so refer to
that section of the documentation directly. A logerror() call points out
that a requested directory is not in the specified directory list. We
can use "list" here without any loss of information.

Signed-off-by: Derrick Stolee <derrickstolee@github.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Documentation/git-daemon.txt
daemon.c