Skip to content

Commit cde7a27

Browse files
committed
mingw: document the experimental standard handle redirection
This feature is still highly experimental and has not even been contributed to the Git mailing list yet: the feature still needs to be battle-tested more. Signed-off-by: Johannes Schindelin <[email protected]>
1 parent 008f14a commit cde7a27

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

Documentation/git.txt

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1180,6 +1180,23 @@ of clones and fetches.
11801180
- any external helpers are named by their protocol (e.g., use
11811181
`hg` to allow the `git-remote-hg` helper)
11821182

1183+
`GIT_REDIRECT_STDIN`::
1184+
`GIT_REDIRECT_STDOUT`::
1185+
`GIT_REDIRECT_STDERR`::
1186+
(EXPERIMENTAL) Windows-only: allow redirecting the standard
1187+
input/output/error handles. This is particularly useful in
1188+
multi-threaded applications where the canonical way to pass
1189+
standard handles via `CreateProcess()` is not an option because
1190+
it would require the handles to be marked inheritable (and
1191+
consequently *every* spawned process would inherit them, possibly
1192+
blocking regular Git operations). The primary intended use case
1193+
is to use named pipes for communication.
1194+
+
1195+
Two special values are supported: `off` will simply close the
1196+
corresponding standard handle, and if `GIT_REDIRECT_STDERR` is
1197+
`2>&1`, standard error will be redirected to the same handle as
1198+
standard output.
1199+
11831200

11841201
Discussion[[Discussion]]
11851202
------------------------

0 commit comments

Comments
 (0)