[intro] Don't give target folder name a (1) suffix when the name is unique

This commit is contained in:
Hylke Bons 2010-08-05 09:27:05 +01:00
parent edcc01b729
commit 71f2b1682b
2 changed files with 7 additions and 4 deletions

View file

@ -125,7 +125,7 @@ namespace SparkleLib {
// Add everything that changed
// since SparkleShare was stopped
// since SparkleShare was stopped TODO: Push if there are changes
AddCommitAndPush ();
SparkleHelpers.DebugInfo ("Git", "[" + Name + "] Idling...");
@ -269,7 +269,7 @@ namespace SparkleLib {
SparkleHelpers.DebugInfo ("Git", "[" + Name + "] Fetching changes...");
Process.StartInfo.Arguments = "fetch -v";
Process.StartInfo.Arguments = "fetch";
Process.WaitForExit ();
Process.Start ();
@ -300,7 +300,7 @@ namespace SparkleLib {
SparkleHelpers.DebugInfo ("Git", "[" + Name + "] Rebasing changes...");
Process.StartInfo.Arguments = "rebase -v master";
Process.StartInfo.Arguments = "rebase -v origin/master";
Process.WaitForExit ();
Process.Start ();

View file

@ -374,7 +374,10 @@ namespace SparkleShare {
}
string target_folder_name = canonical_name + " (" + i + ")";
string target_folder_name = canonical_name;
if (i > 1)
target_folder_name += " (" + i + ")";
Directory.Move (tmp_folder,
SparkleHelpers.CombineMore (SparklePaths.SparklePath, target_folder_name));