From: Dan Mick Date: Thu, 13 Jun 2013 22:30:38 +0000 (-0700) Subject: ceph.in: argparsing cleanup: suppress --completion, add help X-Git-Tag: v0.65~80 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=a6876ad7d949c9d9757e632f10d0bb3bcffddd0a;p=ceph.git ceph.in: argparsing cleanup: suppress --completion, add help Options -v, --verbose, --concise didn't have helpstrings Option --completion doesn't quite work yet, and should be hidden anyway Signed-off-by: Dan Mick --- diff --git a/src/ceph.in b/src/ceph.in index 7d6c62a7303..dcb120931ca 100755 --- a/src/ceph.in +++ b/src/ceph.in @@ -839,7 +839,8 @@ def parse_cmdargs(args=None, target=''): # format our own help parser = AP(description='Frontend for ceph CLI', add_help=False) - parser.add_argument('--completion', action='store_true') + parser.add_argument('--completion', action='store_true', + help=argparse.SUPPRESS) parser.add_argument('-h', '--help', help='request mon help', action='store_true') @@ -878,9 +879,10 @@ def parse_cmdargs(args=None, target=''): parser.add_argument('--watch-error', action='store_true', help='watch error events') - parser.add_argument('-v', action="store_true") - parser.add_argument('--verbose', action="store_true") - parser.add_argument('--concise', dest='verbose', action="store_false") + parser.add_argument('-v', action="store_true", help="display version") + parser.add_argument('--verbose', action="store_true", help="make verbose") + parser.add_argument('--concise', dest='verbose', action="store_false", + help="make less verbose") parser.add_argument('-f', '--format', choices=['json', 'json-pretty', 'xml', 'xml-pretty', 'plain'], dest='output_format')