]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
ceph.in: argparsing cleanup: suppress --completion, add help
authorDan Mick <dan.mick@inktank.com>
Thu, 13 Jun 2013 22:30:38 +0000 (15:30 -0700)
committerDan Mick <dan.mick@inktank.com>
Thu, 13 Jun 2013 22:30:38 +0000 (15:30 -0700)
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 <dan.mick@inktank.com>
src/ceph.in

index 7d6c62a73038093f03b64dbc2692d944d26a4703..dcb120931ca6233d77d1fff2392d542a37357bde 100755 (executable)
@@ -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')