From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: AS31976 209.132.180.0/23 X-Spam-Status: No, score=-5.4 required=3.0 tests=AWL,BAYES_00, FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM,HEADER_FROM_DIFFERENT_DOMAINS, RCVD_IN_DNSWL_HI,RCVD_IN_SORBS_SPAM,RP_MATCHES_RCVD shortcircuit=no autolearn=ham autolearn_force=no version=3.4.0 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by dcvr.yhbt.net (Postfix) with ESMTP id E1CF31F794 for ; Wed, 25 Jan 2017 12:34:35 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751408AbdAYMed (ORCPT ); Wed, 25 Jan 2017 07:34:33 -0500 Received: from mout.gmx.net ([212.227.15.15]:53232 "EHLO mout.gmx.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751386AbdAYMed (ORCPT ); Wed, 25 Jan 2017 07:34:33 -0500 Received: from virtualbox ([37.24.141.236]) by mail.gmx.com (mrgmx001 [212.227.17.190]) with ESMTPSA (Nemesis) id 0Lb5nF-1c3vnE2BIn-00kgOK; Wed, 25 Jan 2017 13:34:25 +0100 Date: Wed, 25 Jan 2017 13:34:21 +0100 (CET) From: Johannes Schindelin X-X-Sender: virtualbox@virtualbox To: Junio C Hamano cc: git@vger.kernel.org, Segev Finer Subject: Re: [PATCH] connect: handle putty/plink also in GIT_SSH_COMMAND In-Reply-To: Message-ID: References: <2ff29a4d00e0e13d460122d8008e762361ca90aa.1483358673.git.johannes.schindelin@gmx.de> User-Agent: Alpine 2.20 (DEB 67 2015-01-07) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII X-Provags-ID: V03:K0:faFUGdC8LaECBVyiXQGheMzqCdcR6a84PSwaW/9L2CxRPy0n83T WTWN2V84AgABmuLMx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: git@vger.kernel.org Hi Junio, On Mon, 9 Jan 2017, Junio C Hamano wrote: > IOW, "give an escape hatch to override auto-detected tortoiseplink and > plink variables" suggestion should be taken as an "in addition to" > suggestion (as opposed to an "instead of" suggestion). I was not clear > in my very first message, and I thought in my second and my third > message I clarified it as such, but probably I wasn't explicit enough. While you may not have been explicit enough, I was not smart enough. That escape-hatch exists *already*. And it is exactly the thing that you mentioned earlier as a potential source of mis-identification. Let's assume that you want to use a script for the GIT_SSH_COMMAND that eventually uses PuTTY, and you call this script "junio-is-a-superstar.sh". All plausible so far ;-) Now, with the patch in question (without the follow-up, which I would like to ask you to ignore, just like you did so far), Git would not figure out that your script calls PuTTY eventually. The work-around? Easy: DUMMY=/plink.exe /path/to/junio-is-a-superstar.sh In other words: the thing that we thought may be a problem is actually a feature. Likewise, if your GIT_SSH_COMMAND looks like this: THIS_IS_NOT_ACTUALLY_PUTTY=/my/window/needs/putty my-ssh.sh ... you can easily change Git's mind by prefixing DUMMY=blubber If you want to use a script that decides itself whether to call OpenSSH or PuTTY, Git should "stay dumb" about it, as it will not be able to tell beforehand whether a port argument should be passed via `-p` or `-P` anyway. Of course, given our discussion I think all of this should be documented in the commit message as well as in the man page. Do you agree this is a good direction to take? Ciao, Johannes