summaryrefslogtreecommitdiff
path: root/Documentation/config/safe.txt
diff options
context:
space:
mode:
authorLibravatar Johannes Schindelin <johannes.schindelin@gmx.de>2022-03-17 10:57:59 +0100
committerLibravatar Johannes Schindelin <johannes.schindelin@gmx.de>2022-03-24 00:31:42 +0100
commit1f480d5127b746c2345701b86f7e15ecbd3377a3 (patch)
tree7061ed3b122a5b45cfe11e2dc18d20f129da6601 /Documentation/config/safe.txt
parentGit 2.35.1 (diff)
parentGit 2.34.2 (diff)
downloadtgif-1f480d5127b746c2345701b86f7e15ecbd3377a3.tar.xz
Sync with 2.34.2
* maint-2.34: Git 2.34.2 Git 2.33.2 Git 2.32.1 Git 2.31.2 GIT-VERSION-GEN: bump to v2.33.1 Git 2.30.3 setup_git_directory(): add an owner check for the top-level directory Add a function to determine whether a path is owned by the current user
Diffstat (limited to 'Documentation/config/safe.txt')
-rw-r--r--Documentation/config/safe.txt21
1 files changed, 21 insertions, 0 deletions
diff --git a/Documentation/config/safe.txt b/Documentation/config/safe.txt
new file mode 100644
index 0000000000..63597b2df8
--- /dev/null
+++ b/Documentation/config/safe.txt
@@ -0,0 +1,21 @@
+safe.directory::
+ These config entries specify Git-tracked directories that are
+ considered safe even if they are owned by someone other than the
+ current user. By default, Git will refuse to even parse a Git
+ config of a repository owned by someone else, let alone run its
+ hooks, and this config setting allows users to specify exceptions,
+ e.g. for intentionally shared repositories (see the `--shared`
+ option in linkgit:git-init[1]).
++
+This is a multi-valued setting, i.e. you can add more than one directory
+via `git config --add`. To reset the list of safe directories (e.g. to
+override any such directories specified in the system config), add a
+`safe.directory` entry with an empty value.
++
+This config setting is only respected when specified in a system or global
+config, not when it is specified in a repository config or via the command
+line option `-c safe.directory=<path>`.
++
+The value of this setting is interpolated, i.e. `~/<path>` expands to a
+path relative to the home directory and `%(prefix)/<path>` expands to a
+path relative to Git's (runtime) prefix.