git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH][resend 2] git-svn: Use GIT_SSH setting if SVN_SSH is not set

From
KRKarthik R <karthikr@fastmail.fm>
Date
Aug 18, 2009, 20:31 UTC
Message-ID
<4A8B0FA8.7040500@fastmail.fm>

If SVN_SSH is defined, it will be used; else value in GIT_SSH is copied to SVN_SSH & then, only on Windows, the \s are escaped.

On Windows, the shell-variables must be set as follows
    GIT_SSH="C:\Program Files\PuTTY\plink.exe"
    SVN_SSH="C:\\Program Files\\PuTTY\\plink.exe"

See http://code.google.com/p/msysgit/issues/detail?id=305 --- Trying again following Dscho's comment (removed MSWin32) & using logic from Junio (don't muck with user's SVN_SSH; else use GIT_SSH to seed SVN_SSH & adjust the \s on Windows)

Previous life of patch: [PATCH] GIT_SSH does not override ssh in git-svn [PATCH][resend] git-svn: Respect GIT_SSH setting

 git-svn.perl |    9 +++++++++
 1 files changed, 9 insertions(+), 0 deletions(-)
diff --git a/git-svn.perl b/git-svn.perl
index b0bfb74..ef86d10 100755
--- a/git-svn.perl
+++ b/git-svn.perl
@@ -21,6 +21,15 @@ $Git::SVN::default_ref_id = $ENV{GIT_SVN_ID} || 
'git-svn';
 $Git::SVN::Ra::_log_window_size = 100;
 $Git::SVN::_minimize_url = 'unset';
 
+if (! exists $ENV{SVN_SSH}) {
+    if (exists $ENV{GIT_SSH}) {
+        $ENV{SVN_SSH} = $ENV{GIT_SSH};
+        if ($^O eq 'msys') {
+            $ENV{SVN_SSH} =~ s/\\/\\\\/g;
+        }
+    }
+}
+
 $Git::SVN::Log::TZ = $ENV{TZ};
 $ENV{TZ} = 'UTC';
 $| = 1; # unbuffer STDOUT
-- 
1.5.4.3
Message 1 of 1 in “[resend 2] git-svn: Use GIT_SSH setting if SVN_SSH is not set”
  1. [resend 2] git-svn: Use GIT_SSH setting if SVN_SSH is not setKarthik R, Aug 18, 2009

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.