jp (base): add --max option:
when MULTI_ITEMS is set, --max options is automatically added, except if NO_MAX flag is set.
This commit is contained in:
parent
b7e2de70d7
commit
d2dadbaf46
1 changed files with 5 additions and 3 deletions
|
|
@ -528,7 +528,6 @@ class Get(base.CommandBase):
|
|||
def add_parser_options(self):
|
||||
self.parser.add_argument("-S", "--sub-id", type=base.unicode_decoder, default=u'',
|
||||
help=_(u"subscription id"))
|
||||
self.parser.add_argument("-m", "--max", type=int, default=10, help=_(u"maximum number of items to get ({} to get all items)".format(C.NO_LIMIT)))
|
||||
# TODO: a key(s) argument to select keys to display
|
||||
# TODO: add MAM filters
|
||||
|
||||
|
|
@ -742,7 +741,7 @@ class Search(base.CommandBase):
|
|||
EXEC_ACTIONS = (u'exec', u'external')
|
||||
|
||||
def __init__(self, host):
|
||||
base.CommandBase.__init__(self, host, 'search', use_output=C.OUTPUT_XML, use_pubsub=True, pubsub_flags={C.MULTI_ITEMS},
|
||||
base.CommandBase.__init__(self, host, 'search', use_output=C.OUTPUT_XML, use_pubsub=True, pubsub_flags={C.MULTI_ITEMS, C.NO_MAX},
|
||||
use_verbose=True, help=_(u'search items corresponding to filters'))
|
||||
self.need_loop=True
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue