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 6201F13888F for ; Sun, 11 Oct 2015 17:26:48 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id C80F9E0858; Sun, 11 Oct 2015 17:26:42 +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 90ADAE0854 for ; Sun, 11 Oct 2015 17:26:41 +0000 (UTC) Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id D087E33FE7D for ; Sun, 11 Oct 2015 17:26:40 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id B10B1DF6 for ; Sun, 11 Oct 2015 17:26:37 +0000 (UTC) From: "Mike Frysinger" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Mike Frysinger" Message-ID: <1444521277.4f358eec1331b8facdbdc7eb36bfd702fd31ad29.vapier@gentoo> Subject: [gentoo-commits] proj/catalyst:master commit in: catalyst/base/ X-VCS-Repository: proj/catalyst X-VCS-Files: catalyst/base/clearbase.py X-VCS-Directories: catalyst/base/ X-VCS-Committer: vapier X-VCS-Committer-Name: Mike Frysinger X-VCS-Revision: 4f358eec1331b8facdbdc7eb36bfd702fd31ad29 X-VCS-Branch: master Date: Sun, 11 Oct 2015 17:26:37 +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: 6c4cedea-244c-4b85-8c87-95f6101c37c7 X-Archives-Hash: b40914de8f70bb48bacf99c7d2980880 commit: 4f358eec1331b8facdbdc7eb36bfd702fd31ad29 Author: Mike Frysinger gentoo org> AuthorDate: Sat Oct 10 05:15:43 2015 +0000 Commit: Mike Frysinger gentoo org> CommitDate: Sat Oct 10 23:54:37 2015 +0000 URL: https://gitweb.gentoo.org/proj/catalyst.git/commit/?id=4f358eec clearbase: convert to log module catalyst/base/clearbase.py | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/catalyst/base/clearbase.py b/catalyst/base/clearbase.py index b2c1a11..3817196 100644 --- a/catalyst/base/clearbase.py +++ b/catalyst/base/clearbase.py @@ -1,5 +1,6 @@ +from catalyst import log from catalyst.support import countdown from catalyst.fileops import clear_dir @@ -15,38 +16,38 @@ class ClearBase(object): def clear_autoresume(self): """ Clean resume points since they are no longer needed """ if "autoresume" in self.settings["options"]: - print "Removing AutoResume Points: ..." + log.notice('Removing AutoResume Points ...') self.resume.clear_all() def remove_autoresume(self): """ Rmove all resume points since they are no longer needed """ if "autoresume" in self.settings["options"]: - print "Removing AutoResume: ..." + log.notice('Removing AutoResume ...') self.resume.clear_all(remove=True) def clear_chroot(self): self.chroot_lock.unlock() - print 'Clearing the chroot path ...' + log.notice('Clearing the chroot path ...') clear_dir(self.settings["chroot_path"], 0755, True) def remove_chroot(self): self.chroot_lock.unlock() - print 'Removing the chroot path ...' + log.notice('Removing the chroot path ...') clear_dir(self.settings["chroot_path"], 0755, True, remove=True) def clear_packages(self, remove=False): if "pkgcache" in self.settings["options"]: - print "purging the pkgcache ..." + log.notice('purging the pkgcache ...') clear_dir(self.settings["pkgcache_path"], remove=remove) def clear_kerncache(self, remove=False): if "kerncache" in self.settings["options"]: - print "purging the kerncache ..." + log.notice('purging the kerncache ...') clear_dir(self.settings["kerncache_path"], remove=remove) @@ -54,15 +55,15 @@ class ClearBase(object): countdown(10,"Purging Caches ...") if any(k in self.settings["options"] for k in ("purge", "purgeonly", "purgetmponly")): - print "purge(); clearing autoresume ..." + log.notice('purge(); clearing autoresume ...') self.clear_autoresume() - print "purge(); clearing chroot ..." + log.notice('purge(); clearing chroot ...') self.clear_chroot() if "purgetmponly" not in self.settings["options"]: - print "purge(); clearing package cache ..." + log.notice('purge(); clearing package cache ...') self.clear_packages(remove) - print "purge(); clearing kerncache ..." + log.notice('purge(); clearing kerncache ...') self.clear_kerncache(remove)