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.77) (envelope-from ) id 1SoHcG-0001DZ-JX for garchives@archives.gentoo.org; Mon, 09 Jul 2012 17:19:20 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 80A74E0605; Mon, 9 Jul 2012 17:19:03 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by pigeon.gentoo.org (Postfix) with ESMTP id 55995E0605 for ; Mon, 9 Jul 2012 17:19:03 +0000 (UTC) Received: from hornbill.gentoo.org (hornbill.gentoo.org [94.100.119.163]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id AC6E01B4022 for ; Mon, 9 Jul 2012 17:19:02 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by hornbill.gentoo.org (Postfix) with ESMTP id 71667E543D for ; Mon, 9 Jul 2012 17:19:01 +0000 (UTC) From: "André Erdmann" To: gentoo-commits@lists.gentoo.org Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "André Erdmann" Message-ID: <1341851260.9fd58ecaad91eb2d0bce5234c5eadc61b7904c36.dywi@gentoo> Subject: [gentoo-commits] proj/R_overlay:master commit in: roverlay/ X-VCS-Repository: proj/R_overlay X-VCS-Files: roverlay/argutil.py X-VCS-Directories: roverlay/ X-VCS-Committer: dywi X-VCS-Committer-Name: André Erdmann X-VCS-Revision: 9fd58ecaad91eb2d0bce5234c5eadc61b7904c36 X-VCS-Branch: master Date: Mon, 9 Jul 2012 17:19:01 +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: 790f050e-36e1-42fe-b0d5-b962f6eb1cc0 X-Archives-Hash: 7e9e6d7c290f679bf38a1649b271d364 commit: 9fd58ecaad91eb2d0bce5234c5eadc61b7904c36 Author: Andr=C3=A9 Erdmann mailerd de> AuthorDate: Mon Jul 9 16:27:40 2012 +0000 Commit: Andr=C3=A9 Erdmann mailerd de> CommitDate: Mon Jul 9 16:27:40 2012 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=3Dproj/R_overlay.git= ;a=3Dcommit;h=3D9fd58eca argutil: --overlay-name and some logic --from / --distdir now implies --nosync and create modified: roverlay/argutil.py --- roverlay/argutil.py | 19 ++++++++++++++----- 1 files changed, 14 insertions(+), 5 deletions(-) diff --git a/roverlay/argutil.py b/roverlay/argutil.py index 4750d15..6249644 100644 --- a/roverlay/argutil.py +++ b/roverlay/argutil.py @@ -119,6 +119,12 @@ def get_parser ( CMD_DESC, DEFAULT_CONFIG ): type=3Dcouldbe_fs_dir ) =20 + arg ( + '--overlay-name', '-N', default=3Dargparse.SUPPRESS, + help=3D"overlay name", + metavar=3D"", + dest=3D"overlay_name" + ) =20 arg ( '--show-overlay', '--show', @@ -215,7 +221,7 @@ def parse_argv ( *args, **kw ): =20 given =3D lambda kw : hasattr ( p, kw ) =20 - + commands =3D ( p.commands, ) if isinstance ( p.commands, str ) else p.c= ommands conf =3D dict() extra =3D dict ( nosync =3D p.nosync, @@ -232,6 +238,9 @@ def parse_argv ( *args, **kw ): doconf ( p.overlay, 'OVERLAY.dir' ) extra ['write_overlay'] =3D True =20 + if given ( 'overlay_name' ): + doconf ( p.overlay_name, 'OVERLAY.name' ) + if given ( 'field_definition' ): doconf ( p.field_definition, 'DESCRIPTION.field_definition_file' ) =20 @@ -244,6 +253,9 @@ def parse_argv ( *args, **kw ): if given ( 'distdirs' ): doconf ( (), 'REPO.config_files' ) extra ['distdirs'] =3D frozenset ( p.distdirs ) + extra ['nosync'] =3D True + # FIXME: COMMANDS are unknown here (theoretically) + commands.append ( "create" ) # FIXME: # distdir implies --nosync, but LocalRepo doesn't care about that ( sy= nc() is nosync() ) =20 @@ -251,8 +263,5 @@ def parse_argv ( *args, **kw ): doconf ( p.deprule_file, 'DEPRES.SIMPLE_RULES.files' ) =20 =20 - return ( - ( p.commands, ) if isinstance ( p.commands, str ) else p.commands, - p.config, conf, extra - ) + return ( commands, p.config, conf, extra ) # --- end of parse_argv (...) ---