From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id A14EE1382C5 for ; Tue, 6 Feb 2018 11:57:46 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 9DE04E0A8F; Tue, 6 Feb 2018 11:57:45 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 78DE1E0A8F for ; Tue, 6 Feb 2018 11:57:45 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id D60C3335C4D for ; Tue, 6 Feb 2018 11:57:42 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 149EC1C9 for ; Tue, 6 Feb 2018 11:57:40 +0000 (UTC) From: "Anthony G. Basile" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Anthony G. Basile" Message-ID: <1517918251.d3100bd866cb5339b897378894f79bcd51ede89c.blueness@gentoo> Subject: [gentoo-commits] proj/grss:master commit in: grs/ X-VCS-Repository: proj/grss X-VCS-Files: grs/Synchronize.py X-VCS-Directories: grs/ X-VCS-Committer: blueness X-VCS-Committer-Name: Anthony G. Basile X-VCS-Revision: d3100bd866cb5339b897378894f79bcd51ede89c X-VCS-Branch: master Date: Tue, 6 Feb 2018 11:57:40 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: 97275160-d2b7-4b12-ad0a-5d839d258284 X-Archives-Hash: 35797dd9769ca36934b9e1fc5d7d8bbd commit: d3100bd866cb5339b897378894f79bcd51ede89c Author: Anthony G. Basile gentoo org> AuthorDate: Tue Feb 6 11:57:31 2018 +0000 Commit: Anthony G. Basile gentoo org> CommitDate: Tue Feb 6 11:57:31 2018 +0000 URL: https://gitweb.gentoo.org/proj/grss.git/commit/?id=d3100bd8 grs/Synchronize.py: checkout the branch before updating the submodule grs/Synchronize.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/grs/Synchronize.py b/grs/Synchronize.py index 8a55c84..d2d4cb5 100644 --- a/grs/Synchronize.py +++ b/grs/Synchronize.py @@ -43,6 +43,10 @@ class Synchronize(): cmd = 'git clone %s %s' % (self.remote_repo, self.local_repo) Execute(cmd, timeout=60, logfile=self.logfile) + # Make sure we're on the correct branch for the desired GRS system. + cmd = 'git -C %s checkout %s' % (self.local_repo, self.branch) + Execute(cmd, timeout=60, logfile=self.logfile) + # If there is a .gitmodules, then init/update the submodules git_modulesfile = os.path.join(self.local_repo, '.gitmodules') if os.path.isfile(git_modulesfile): @@ -53,10 +57,6 @@ class Synchronize(): cmd = 'git -C %s submodule update' % self.local_repo Execute(cmd, timeout=60, logfile=self.logfile) - # Make sure we're on the correct branch for the desired GRS system. - cmd = 'git -C %s checkout %s' % (self.local_repo, self.branch) - Execute(cmd, timeout=60, logfile=self.logfile) - def isgitdir(self): """ If there is a .git/config file, assume its a local git repository. """