From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id E11B31385DD for ; Fri, 4 Sep 2015 17:29:38 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 7F0C414203; Fri, 4 Sep 2015 17:29:36 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id E78D2141E9 for ; Fri, 4 Sep 2015 17:29:35 +0000 (UTC) Received: from localhost (S010634bdfa9ecf80.vc.shawcable.net [96.49.31.57]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: dolsen) by smtp.gentoo.org (Postfix) with ESMTPSA id 2FA5C340768 for ; Fri, 4 Sep 2015 17:29:35 +0000 (UTC) Date: Fri, 4 Sep 2015 10:29:29 -0700 From: Brian Dolbec To: gentoo-portage-dev@lists.gentoo.org Subject: Re: [gentoo-portage-dev] [PATCH] git sync: Respect PORTAGE_QUIET Message-ID: <20150904102929.71bb3d3c.dolsen@gentoo.org> In-Reply-To: <20150904102027.GB11432@daphne> References: <20150904102027.GB11432@daphne> Organization: Gentoo Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-portage-dev@lists.gentoo.org Reply-to: gentoo-portage-dev@lists.gentoo.org MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Archives-Salt: 75056c77-2798-44c4-bb5d-33acf0f00631 X-Archives-Hash: aeff917cfb66f904e8c3eb636dc82a51 On Fri, 4 Sep 2015 10:20:27 +0000 Consus wrote: > Execute `git clone --quiet' and `git pull --quiet' when appropriate. > --- > pym/portage/sync/modules/git/git.py | 20 +++++++++++++------- > 1 file changed, 13 insertions(+), 7 deletions(-) > > diff --git a/pym/portage/sync/modules/git/git.py > b/pym/portage/sync/modules/git/git.py index 7a710ef..c14782c 100644 > --- a/pym/portage/sync/modules/git/git.py > +++ b/pym/portage/sync/modules/git/git.py > @@ -1,4 +1,4 @@ > -# Copyright 2005-2014 Gentoo Foundation > +# Copyright 2005-2015 Gentoo Foundation > # Distributed under the terms of the GNU General Public License v2 > > import logging > @@ -43,15 +43,18 @@ class GitSync(NewBase): > 'Created new directory %s' % > self.repo.location) except IOError: > return (1, False) > + > sync_uri = self.repo.sync_uri > if sync_uri.startswith("file://"): > sync_uri = sync_uri[6:] > - depth_arg = '' > - if self.repo.sync_depth is not None: > - depth_arg = '--depth %d ' % > self.repo.sync_depth > - git_cmd = "%s clone %s%s ." % (self.bin_command, > depth_arg, > - portage._shell_quote(sync_uri)) > + git_cmd_opts = "" > + if self.settings.get("PORTAGE_QUIET") == "1": > + git_cmd_opts += " --quiet" > + if self.repo.sync_depth is not None: > + git_cmd_opts += " --depth %d" % > self.repo.sync_depth > + git_cmd = "%s clone%s %s ." % (self.bin_command, > git_cmd_opts, > + portage._shell_quote(sync_uri)) > writemsg_level(git_cmd + "\n") > > exitcode = portage.process.spawn_bash("cd %s ; exec > %s" % ( @@ -72,7 +75,10 @@ class GitSync(NewBase): > git directly. > ''' > > - git_cmd = "%s pull" % self.bin_command > + git_cmd_opts = "" > + if self.settings.get("PORTAGE_QUIET") == "1": > + git_cmd_opts += " --quiet" > + git_cmd = "%s pull%s" % (self.bin_command, > git_cmd_opts) writemsg_level(git_cmd + "\n") > > exitcode = portage.process.spawn_bash("cd %s ; exec > %s" % ( merged and pushed to master Thank you -- Brian Dolbec