From d542f3e75a2bc6b49f94f2bc3c3dd63502bcfc1b Mon Sep 17 00:00:00 2001 From: Hylke Bons Date: Mon, 16 Apr 2012 23:26:08 +0200 Subject: [PATCH] repo git: quote urls to allow push/pull with urls that contain spaces. Fixes #703 --- SparkleLib/Git/SparkleRepoGit.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/SparkleLib/Git/SparkleRepoGit.cs b/SparkleLib/Git/SparkleRepoGit.cs index 8d259734..a1744ed5 100644 --- a/SparkleLib/Git/SparkleRepoGit.cs +++ b/SparkleLib/Git/SparkleRepoGit.cs @@ -161,7 +161,7 @@ namespace SparkleLib.Git { { get { SparkleHelpers.DebugInfo ("Git", "[" + Name + "] Checking for remote changes..."); - SparkleGit git = new SparkleGit (LocalPath, "ls-remote " + Url + " master"); + SparkleGit git = new SparkleGit (LocalPath, "ls-remote \"" + Url + "\" master"); git.Start (); git.WaitForExit (); @@ -196,7 +196,7 @@ namespace SparkleLib.Git { SparkleGit git = new SparkleGit (LocalPath, "push --progress " + // Redirects progress stats to standarderror - Url + " master"); + "\"" + Url + "\" master"); git.StartInfo.RedirectStandardError = true; git.Start (); @@ -259,7 +259,7 @@ namespace SparkleLib.Git { public override bool SyncDown () { - SparkleGit git = new SparkleGit (LocalPath, "fetch --progress " + Url); + SparkleGit git = new SparkleGit (LocalPath, "fetch --progress \"" + Url + "\" master"); git.StartInfo.RedirectStandardError = true; git.Start ();