public static string AddRemote(string name, string path)
{
var location = FixPath(path);
if (string.IsNullOrEmpty(name))
return "Please enter a name.";
return
string.IsNullOrEmpty(location)
? RunCmd(Settings.GitCommand, string.Format("remote add \"{0}\" \"\"", name))
: RunCmd(Settings.GitCommand, string.Format("remote add \"{0}\" \"{1}\"", name, location));
}