Document that 'git -C ""' works and doesn't change directory
It's been behaving so since 6a536e2076 (git: treat "git -C '<path>'" as a no-op when <path> is empty, 2015-03-06). Signed-off-by: SZEDER Gábor <szeder.dev@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
SZEDER Gábor committed
Jun 29, 2019 at 10:24 UTC
1a64e07d235579ae0b3bc6d1f081a51a6e48a4d1
1 file changed
+2
-1
Documentation/git.txt
+2
-1
@@ -56,7 +56,8 @@ help ...`.
56
Run as if git was started in '<path>' instead of the current working
57
directory. When multiple `-C` options are given, each subsequent
58
non-absolute `-C <path>` is interpreted relative to the preceding `-C
59
- <path>`.
59
+ <path>`. If '<path>' is present but empty, e.g. `-C ""`, then the
60
+ current working directory is left unchanged.
61
+
62
This option affects options that expect path name like `--git-dir` and
63
`--work-tree` in that their interpretations of the path names would be