From: Guido Günther Date: Thu, 4 Jul 2013 15:45:54 +0000 (+0200) Subject: GitRepository.set_upstream_branch: don't try to set upstream twice X-Git-Tag: debian/0.6.2~4 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=7762b17e1583356f9ba7e4484dd474c988dba12c;p=tools%2Fgit-buildpackage.git GitRepository.set_upstream_branch: don't try to set upstream twice Move setting of the upstream branch out of the loop. This worked by accident. --- diff --git a/gbp/git/repository.py b/gbp/git/repository.py index 11aff4fd..e172aad6 100644 --- a/gbp/git/repository.py +++ b/gbp/git/repository.py @@ -538,8 +538,8 @@ class GitRepository(object): if not self.has_branch(branch, remote=remote): raise GitRepositoryError("Branch %s doesn't exist!" % branch) - self._git_inout('branch', ["--set-upstream", local_branch, upstream], - capture_stderr=True) + self._git_inout('branch', ["--set-upstream", local_branch, upstream], + capture_stderr=True) def get_upstream_branch(self, local_branch): """