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

Re: [PATCH] If deriving SVN_SSH from GIT_SSH on msys, also add quotes

From
Sebastian Schuberth <sschuberth@gmail.com>
Date
Jan 23, 2010, 14:20 UTC
Message-ID
<4B5B05AC.2050200@gmail.com>
In-Reply-To
<fabb9a1e1001230322t708756fahce326511d3f0bda5@mail.gmail.com>

In contrast to GIT_SSH, SVN_SSH requires quotes for paths that contain spaces. As GIT_SSH will not work if it contains quotes, it is safe to assume it never contains quotes. Also, adding quotes to SVN_SSH for paths that do not contain spaces does no harm. So we always add quotes when deriving SVN_SSH from GIT_SSH.

This fixes msysGit issue 385, see http://code.google.com/p/msysgit/issues/detail?id=385

Signed-off-by: Sebastian Schuberth <sschuberth@gmail.com>
---
 git-svn.perl |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/git-svn.perl b/git-svn.perl
index 650c9e5..ef39a9f 100755
--- a/git-svn.perl
+++ b/git-svn.perl
@@ -26,6 +26,7 @@ if (! exists $ENV{SVN_SSH}) {
 		$ENV{SVN_SSH} = $ENV{GIT_SSH};
 		if ($^O eq 'msys') {
 			$ENV{SVN_SSH} =~ s/\\/\\\\/g;
+			$ENV{SVN_SSH} =~ s/(.*)/"$1"/;
 		}
 	}
 }
-- 
1.6.6.265.ga0f40
Previous: Sverre RabbelierNext: Junio C Hamano
Message 3 of 5 in “If deriving SVN_SSH from GIT_SSH on msys, also add quotes”
  1. If deriving SVN_SSH from GIT_SSH on msys, also add quotesSebastian Schuberth, Jan 23, 2010
  2. Sverre RabbelierJan 23, 2010
  3. Sebastian SchuberthJan 23, 2010
  4. Junio C HamanoJan 23, 2010
  5. Sebastian SchuberthJan 23, 2010

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.