# HG changeset patch # User Bjoern Ricks # Date 1314955586 0 # Node ID bee73fd5bb82e71fed06ea965c5277def235ee5a # Parent 9824e409388bf8663c455a22e2799fd825548cbd Set default branch to "master" diff -r 9824e409388b -r bee73fd5bb82 treepkg/git.py --- a/treepkg/git.py Fri Sep 02 08:45:28 2011 +0000 +++ b/treepkg/git.py Fri Sep 02 09:26:26 2011 +0000 @@ -36,13 +36,13 @@ self.url = url self.local_branch = "local" self.branch = branch + if not branch: + self.branch = "master" if ":" in branch: branches = branch.split(":") self.local_branch = branches[0] self.branch = branches[1] # use master as default - if not branch: - self.branch = "master" def checkout(self, localdir): """Clones the repository at url into the localdir"""