From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1RHGpC-0006GG-JV for garchives@archives.gentoo.org; Fri, 21 Oct 2011 15:15:58 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id C300F21C059; Fri, 21 Oct 2011 15:15:51 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by pigeon.gentoo.org (Postfix) with ESMTP id 988B921C059 for ; Fri, 21 Oct 2011 15:15:51 +0000 (UTC) Received: from pelican.gentoo.org (unknown [66.219.59.40]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 1ED691B4010 for ; Fri, 21 Oct 2011 15:15:51 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by pelican.gentoo.org (Postfix) with ESMTP id 3FF0580042 for ; Fri, 21 Oct 2011 15:15:50 +0000 (UTC) From: "Paweł Hajdan" To: gentoo-commits@lists.gentoo.org Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Paweł Hajdan" Message-ID: <9b8ef056ffe123fdd90e5c156f8c6ce532376db9.phajdan.jr@gentoo> Subject: [gentoo-commits] proj/arch-tools:master commit in: / X-VCS-Repository: proj/arch-tools X-VCS-Files: batch-stabilize.py X-VCS-Directories: / X-VCS-Committer: phajdan.jr X-VCS-Committer-Name: Paweł Hajdan X-VCS-Revision: 9b8ef056ffe123fdd90e5c156f8c6ce532376db9 Date: Fri, 21 Oct 2011 15:15:50 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: quoted-printable X-Archives-Salt: X-Archives-Hash: 012ade44105b22813441e523db73b742 commit: 9b8ef056ffe123fdd90e5c156f8c6ce532376db9 Author: Pawel Hajdan, Jr gentoo org> AuthorDate: Fri Oct 21 15:14:28 2011 +0000 Commit: Pawe=C5=82 Hajdan gentoo org> CommitDate: Fri Oct 21 15:14:28 2011 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=3Dproj/arch-tools.gi= t;a=3Dcommit;h=3D9b8ef056 Fix bugs: - open log in append mode to avoid losing logs on retry - delete old ChangeLogs to avoid adding the same entry multiple times - re-Manifest after ekeyword to avoid manifest error on dependent packages --- batch-stabilize.py | 12 +++++++++++- 1 files changed, 11 insertions(+), 1 deletions(-) diff --git a/batch-stabilize.py b/batch-stabilize.py index b76bac7..0289c42 100755 --- a/batch-stabilize.py +++ b/batch-stabilize.py @@ -100,19 +100,29 @@ if __name__ =3D=3D "__main__": print 'Sanity check failed. Please make sure your CVS repo is up to d= ate (cvs up).' sys.exit(1) =20 - with open('batch-stabilize.log', 'w') as log_file: + with open('batch-stabilize.log', 'a') as log_file: for bug_id in stabilization_dict: print_and_log('Working on bug %d...' % bug_id, log_file) commit_message =3D "%s stable wrt bug #%d" % (options.arch, bug_id) for (pn, ebuild_name) in stabilization_dict[bug_id]: cvs_path =3D os.path.join(options.repo, pn) print_and_log('Working in %s...' % cvs_path, log_file) + + # Remove existing changelog to avoid adding duplicate entries. + try: + os.remove(os.path.join(cvs_path, 'ChangeLog')) + except OSError: + pass + if run_command(["cvs", "up"], cvs_path, log_file)[0] !=3D 0: print '!!! cvs up failed' sys.exit(1) if run_command(["ekeyword", options.arch, ebuild_name], cvs_path, l= og_file)[0] !=3D 0: print '!!! ekeyword failed' sys.exit(1) + if run_command(["repoman", "manifest"], cvs_path, log_file)[0] !=3D= 0: + print '!!! repoman manifest failed' + sys.exit(1) for (pn, ebuild_name) in stabilization_dict[bug_id]: cvs_path =3D os.path.join(options.repo, pn) print_and_log('Working in %s...' % cvs_path, log_file)