All of lore.kernel.org
 help / color / mirror / Atom feed
From: Karthik R <karthikr@fastmail.fm>
To: Johannes Schindelin <Johannes.Schindelin@gmx.de>
Cc: git@vger.kernel.org
Subject: Re: [PATCH][resend] git-svn: Respect GIT_SSH setting
Date: Mon, 17 Aug 2009 23:33:02 -0500	[thread overview]
Message-ID: <4A8A2EFE.6000203@fastmail.fm> (raw)
In-Reply-To: <alpine.DEB.1.00.0908180117140.8306@pacific.mpi-cbg.de>

Johannes Schindelin wrote:
> Hi,
>
> On Mon, 17 Aug 2009, Karthik R wrote:
>
>   
>> Setting GIT_SSH when using "git svn clone svn+ssh://..." does not
>> override the default ssh; SVN_SSH needed to be set instead.
>>     
>
> This is now in past tense, no?
>
>   
Yes... this is all in the past tense now :) ... should be "did not 
override the default ssh". I'll fix it if I have to resend the patch for 
a different reason.
>> diff --git a/git-svn.perl b/git-svn.perl
>> index b0bfb74..9bc1e71 100755
>> --- a/git-svn.perl
>> +++ b/git-svn.perl
>> @@ -21,6 +21,13 @@ $Git::SVN::default_ref_id = $ENV{GIT_SVN_ID} || 'git-svn';
>> $Git::SVN::Ra::_log_window_size = 100;
>> $Git::SVN::_minimize_url = 'unset';
>>
>> +# If GIT_SSH is set, also set SVN_SSH...
>> +$ENV{SVN_SSH} = $ENV{GIT_SSH} if defined $ENV{GIT_SSH};
>> +# ... and escape \s in shell-variable on Windows
>> +if ($^O eq 'MSWin32' || $^O eq 'msys') {
>> +       $ENV{SVN_SSH} =~ s/\\/\\\\/g if defined $ENV{SVN_SSH};
>> +}
>>     
>
> This is a change from before... I do not know if it is a good one, as 
> SVN_SSH could be defined differently by the user, no?  In that case, the 
> user was most likely using the correct amount of backslashes...
>   
Dscho, The *correct* amount of backslashes is 1 (per dir) - same as used 
with GIT_SSH. If the user has set SVN_SSH but not GIT_SSH (most likely 
without escaping \), then fixing up SVN_SSH for use with git-svn is not 
a bad thing.

I did this change to retain existing behavior (using SVN_SSH to 
override) even when user doesn't know the \\ quirk - or if the user has 
set it for some other non-msys version of svn.
> So maybe it was correct to make this dependent on "if defined 
> $ENV{GIT_SSH}", and maybe it should be dependent on "&& !defined 
> $ENV{SVN_SSH}" as well...
>
> Ciao,
> Dscho
>
>   

  reply	other threads:[~2009-08-18  4:33 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-08-17 23:02 [PATCH][resend] git-svn: Respect GIT_SSH setting Karthik R
2009-08-17 23:20 ` Johannes Schindelin
2009-08-18  4:33   ` Karthik R [this message]
2009-08-18  9:52     ` Johannes Schindelin
2009-08-17 23:21 ` Junio C Hamano
2009-08-17 23:47   ` Karthik R
2009-08-18  5:48     ` Karthik R
2009-08-18 19:25     ` Junio C Hamano

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4A8A2EFE.6000203@fastmail.fm \
    --to=karthikr@fastmail.fm \
    --cc=Johannes.Schindelin@gmx.de \
    --cc=git@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.