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 169BB1389F5 for ; Mon, 17 Nov 2014 00:55:34 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id BE211E0D63; Mon, 17 Nov 2014 00:55:30 +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 EC2E3E0D4F for ; Mon, 17 Nov 2014 00:55:29 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id C1448340327 for ; Mon, 17 Nov 2014 00:55:27 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id D93FC29FF for ; Mon, 17 Nov 2014 00:55:24 +0000 (UTC) From: "Brian Dolbec" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Brian Dolbec" Message-ID: <1416185592.5ac501632bd8a8747d6164517e8e48124fdd5239.dol-sen@gentoo> Subject: [gentoo-commits] proj/portage:repoman commit in: pym/repoman/modules/commit/, pym/repoman/ X-VCS-Repository: proj/portage X-VCS-Files: pym/repoman/argparser.py pym/repoman/copyrights.py pym/repoman/main.py pym/repoman/modules/commit/repochecks.py X-VCS-Directories: pym/repoman/modules/commit/ pym/repoman/ X-VCS-Committer: dol-sen X-VCS-Committer-Name: Brian Dolbec X-VCS-Revision: 5ac501632bd8a8747d6164517e8e48124fdd5239 X-VCS-Branch: repoman Date: Mon, 17 Nov 2014 00:55:24 +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: a25a15a1-811f-4071-8c75-20e1ca511ba3 X-Archives-Hash: 1defade8e39879f63f49a93a9e4bc6d6 commit: 5ac501632bd8a8747d6164517e8e48124fdd5239 Author: Tom Wijsman gentoo org> AuthorDate: Mon Jun 2 18:28:34 2014 +0000 Commit: Brian Dolbec gmail com> CommitDate: Mon Nov 17 00:53:12 2014 +0000 URL: http://sources.gentoo.org/gitweb/?p=proj/portage.git;a=commit;h=5ac50163 repoman: Fix up commit imports and calls --- pym/repoman/argparser.py | 3 ++- pym/repoman/copyrights.py | 2 +- pym/repoman/main.py | 24 ++++++++++++++---------- pym/repoman/modules/commit/repochecks.py | 3 ++- 4 files changed, 19 insertions(+), 13 deletions(-) diff --git a/pym/repoman/argparser.py b/pym/repoman/argparser.py index 19ec6e9..393d755 100644 --- a/pym/repoman/argparser.py +++ b/pym/repoman/argparser.py @@ -6,6 +6,7 @@ import logging import portage +import sys from portage import util from portage.util._argparse import ArgumentParser @@ -167,7 +168,7 @@ def parse_args(argv, qahelp, repoman_default_opts): opts, args = parser.parse_known_args(argv[1:]) if not opts.ignore_default_opts: - default_opts = portage.util.shlex_split(repoman_default_opts) + default_opts = util.shlex_split(repoman_default_opts) if default_opts: opts, args = parser.parse_known_args(default_opts + sys.argv[1:]) diff --git a/pym/repoman/copyrights.py b/pym/repoman/copyrights.py index 231857f..01ce42f 100644 --- a/pym/repoman/copyrights.py +++ b/pym/repoman/copyrights.py @@ -83,7 +83,7 @@ def update_copyright(fn_path, year, pretend=False): new_header.append(line) break - line = _update_copyright_year(year, line) + line = update_copyright_year(year, line) new_header.append(line) difflines = 0 diff --git a/pym/repoman/main.py b/pym/repoman/main.py index 9ce3c18..d567f94 100755 --- a/pym/repoman/main.py +++ b/pym/repoman/main.py @@ -56,7 +56,7 @@ from repoman.checks.ebuilds.misc import bad_split_check, pkg_invalid from repoman.checks.ebuilds.pkgmetadata import PkgMetadata from repoman.ebuild import Ebuild from repoman.errors import err -from repoman.modules import commit +from repoman.modules.commit import repochecks from repoman.profile import check_profiles, dev_keywords, setup_profile from repoman.qa_data import (format_qa_output, format_qa_output_column, qahelp, qawarnings, qacats, max_desc_len, missingvars, @@ -187,8 +187,8 @@ repolevel = len(reposplit) ################### if options.mode == 'commit': - commit.repochecks.commit_check(repolevel, reposplit) - commit.repochecks.conflict_check(vcs_settings, options) + repochecks.commit_check(repolevel, reposplit) + repochecks.conflict_check(vcs_settings, options) ################### @@ -265,7 +265,8 @@ check_ebuild_notadded = not \ effective_scanlist = scanlist if options.if_modified == "y": effective_scanlist = sorted(vcs_files_to_cps( - chain(changed.changed, changed.new, changed.removed))) + chain(changed.changed, changed.new, changed.removed), + repolevel, reposplit, categories)) for xpkg in effective_scanlist: # ebuilds and digests added to cvs respectively. @@ -1266,7 +1267,8 @@ else: else: commitmessage = utilities.get_commit_message_with_stdin() except KeyboardInterrupt: - exithandler() + logging.fatal("Interrupted; exiting...") + sys.exit(1) if not commitmessage or not commitmessage.strip(): print("* no commit message? aborting commit.") sys.exit(1) @@ -1326,7 +1328,8 @@ else: logging.info("checking for unmodified ChangeLog files") committer_name = utilities.get_committer_name(env=repoman_settings) for x in sorted(vcs_files_to_cps( - chain(myupdates, mymanifests, myremoved))): + chain(myupdates, mymanifests, myremoved), + repolevel, reposplit, categories)): catdir, pkgdir = x.split("/") checkdir = repo_settings.repodir + "/" + x checkdir_relative = "" @@ -1466,7 +1469,7 @@ else: print("%s have headers that will change." % green(str(len(myheaders)))) print( - "* Files with headers will " + "* Files with headers will" " cause the manifests to be changed and committed separately.") logging.info("myupdates: %s", myupdates) @@ -1621,9 +1624,9 @@ else: "doing the entire repository.\"\n") if vcs_settings.vcs in ('cvs', 'svn') and (myupdates or myremoved): - for x in sorted(vcs_files_to_cps( - chain(myupdates, myremoved, mymanifests))): + chain(myupdates, myremoved, mymanifests), + repolevel, reposplit, categories)): repoman_settings["O"] = os.path.join(repo_settings.repodir, x) digestgen(mysettings=repoman_settings, myportdb=portdb) @@ -1637,7 +1640,8 @@ else: signed = True try: for x in sorted(vcs_files_to_cps( - chain(myupdates, myremoved, mymanifests))): + chain(myupdates, myremoved, mymanifests), + repolevel, reposplit, categories)): repoman_settings["O"] = os.path.join(repo_settings.repodir, x) manifest_path = os.path.join(repoman_settings["O"], "Manifest") if not need_signature(manifest_path): diff --git a/pym/repoman/modules/commit/repochecks.py b/pym/repoman/modules/commit/repochecks.py index ac4db6b..d0e2f28 100644 --- a/pym/repoman/modules/commit/repochecks.py +++ b/pym/repoman/modules/commit/repochecks.py @@ -3,7 +3,8 @@ from portage.output import red from repoman.errors import err -from repoman.vcs import detect_vcs_conflicts +from repoman.vcs import vcs +from repoman.vcs.vcs import detect_vcs_conflicts def commit_check(repolevel, reposplit):