Merge branch 'ma/sequencer-do-reset-saner-loop-termination'
[gitweb.git] / Documentation / config.txt
index 10617d0a10d0a1ee88c0929e4caa631d2ef24793..3e735f1a9a092eef091aaa4c7536aecff1f2807f 100644 (file)
@@ -2,8 +2,9 @@ CONFIGURATION FILE
 ------------------
 
 The Git configuration file contains a number of variables that affect
-the Git commands' behavior. The `.git/config` file in each repository
-is used to store the configuration for that repository, and
+the Git commands' behavior. The files `.git/config` and optionally
+`config.worktree` (see `extensions.worktreeConfig` below) in each
+repository are used to store the configuration for that repository, and
 `$HOME/.gitconfig` is used to store a per-user configuration as
 fallback values for the `.git/config` file. The file `/etc/gitconfig`
 can be used to store a system-wide default configuration.
@@ -291,6 +292,13 @@ include::config/advice.txt[]
 
 include::config/core.txt[]
 
+extensions.worktreeConfig::
+       If set, by default "git config" reads from both "config" and
+       "config.worktree" file from GIT_DIR in that order. In
+       multiple working directory mode, "config" file is shared while
+       "config.worktree" is per-working directory (i.e., it's in
+       GIT_COMMON_DIR/worktrees/<id>/config.worktree)
+
 include::config/add.txt[]
 
 include::config/alias.txt[]
@@ -435,12 +443,4 @@ include::config/versionsort.txt[]
 
 include::config/web.txt[]
 
-worktree.guessRemote::
-       With `add`, if no branch argument, and neither of `-b` nor
-       `-B` nor `--detach` are given, the command defaults to
-       creating a new branch from HEAD.  If `worktree.guessRemote` is
-       set to true, `worktree add` tries to find a remote-tracking
-       branch whose name uniquely matches the new branch name.  If
-       such a branch exists, it is checked out and set as "upstream"
-       for the new branch.  If no such match can be found, it falls
-       back to creating a new branch from the current HEAD.
+include::config/worktree.txt[]