diff options
author | Tim Harder <radhermit@gmail.com> | 2015-11-29 00:46:17 -0500 |
---|---|---|
committer | Tim Harder <radhermit@gmail.com> | 2015-11-29 00:46:17 -0500 |
commit | 593a771d67714db682e16e22f0bb33e07ff303cd (patch) | |
tree | 5e17427d89ce1cc8043d510e2c6af73c1c9bd6e6 | |
parent | pquery: add initial short versions of repo type options (diff) | |
download | pkgcore-pquery.tar.gz pkgcore-pquery.tar.bz2 pkgcore-pquery.zip |
pquery: sort output option into more logical locationspquery
-rw-r--r-- | pkgcore/scripts/pquery.py | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/pkgcore/scripts/pquery.py b/pkgcore/scripts/pquery.py index ca9260e22..6d2bbcd35 100644 --- a/pkgcore/scripts/pquery.py +++ b/pkgcore/scripts/pquery.py @@ -791,6 +791,18 @@ output = argparser.add_argument_group('Output formatting') output.add_argument( '--early-out', action='store_true', dest='earlyout', help='stop when first match is found') +output.add_argument( + '-a', '--atom', action=commandline.Expansion, + subst=(('--cpv',),), nargs=0, + help='print =cat/pkg-3 instead of cat/pkg-3. ' + 'Implies --cpv, has no effect with --no-version') +output.add_argument( + '--cpv', action='store_true', + help='print the category/package-version', + docs=""" + This is done by default, this option re-enables this if another output + option (like --contents) disabled it. + """) output_mux = output.add_mutually_exclusive_group() output_mux.add_argument( '-n', '--no-version', action='store_true', @@ -804,18 +816,6 @@ output_mux.add_argument( help='show only the highest version for each package') del output_mux output.add_argument( - '--cpv', action='store_true', - help='print the category/package-version', - docs=""" - This is done by default, this option re-enables this if another output - option (like --contents) disabled it. - """) -output.add_argument( - '-a', '--atom', action=commandline.Expansion, - subst=(('--cpv',),), nargs=0, - help='print =cat/pkg-3 instead of cat/pkg-3. ' - 'Implies --cpv, has no effect with --no-version') -output.add_argument( '--attr', action='append', choices=printable_attrs, metavar='attribute', default=[], help="print this attribute's value (can be specified more than " @@ -839,6 +839,10 @@ one_attr_mux.add_argument( 'supported names') del one_attr_mux output.add_argument( + '--blame', action=commandline.Expansion, nargs=0, + subst=(("--attr", "maintainers"), ("--attr", "herds")), + help='shorthand for --attr maintainers --attr herds') +output.add_argument( '--contents', action='store_true', help='list files owned by the package') output.add_argument( @@ -849,10 +853,6 @@ output.add_argument( type=atom.atom, default=[], help='highlight dependencies matching this atom') output.add_argument( - '--blame', action=commandline.Expansion, nargs=0, - subst=(("--attr", "maintainers"), ("--attr", "herds")), - help='shorthand for --attr maintainers --attr herds') -output.add_argument( '--print-revdep', action='append', type=atom.atom, default=[], help='print what condition(s) trigger a dep') |