aboutsummaryrefslogtreecommitdiff
path: root/doc/git-annex.mdwn
diff options
context:
space:
mode:
authorGravatar Joey Hess <joeyh@joeyh.name>2017-04-07 11:35:20 -0400
committerGravatar Joey Hess <joeyh@joeyh.name>2017-04-07 11:35:27 -0400
commit9cbe5068f837d71dbcfd884d5ebfcb105600a85d (patch)
tree167098f49a5d6e088c2612173300568aab88fd44 /doc/git-annex.mdwn
parent44bd2dedc7819a37bb3ad663be276528b39feb8d (diff)
Disable git-annex's support for GIT_SSH and GIT_SSH_COMMAND, unless GIT_ANNEX_USE_GIT_SSH=1 is also set in the environment.
This is necessary because as feared, the extra -n parameter that git-annex passes breaks uses of these environment variables that expect exactly the parameters that git passes. For example, see https://github.com/datalad/datalad/issues/1456 It would of course be possible to pre-close stdin before running ssh so not needing the -n, and I think that would not even break ssh's password caching. But it would probably involve a lot of work, possibly would need to deal with some layering violations, and would be error-prone. The really clean fix would be to make all the ssh stuff return a CreateProcess, which could have the handle closed when appropriate, but that would be a large reworing of the code base. This commit was supported by the NSF-funded DataLad project.
Diffstat (limited to 'doc/git-annex.mdwn')
-rw-r--r--doc/git-annex.mdwn5
1 files changed, 4 insertions, 1 deletions
diff --git a/doc/git-annex.mdwn b/doc/git-annex.mdwn
index 2bebd9f49..56be4bcf9 100644
--- a/doc/git-annex.mdwn
+++ b/doc/git-annex.mdwn
@@ -1434,7 +1434,10 @@ These environment variables are used by git-annex when set:
Handled similarly to the same as described in git(1).
The one difference is that git-annex will sometimes pass an additional
"-n" parameter to these, as the first parameter, to prevent ssh from
- reading from stdin.
+ reading from stdin. Since that can break existing uses of these
+ environment variables that don't expect the extra parameter, you will
+ need to set `GIT_ANNEX_USE_GIT_SSH=1` to make git-annex support
+ these.
Note that setting either of these environment variables prevents
git-annex from automatically enabling ssh connection caching