mirror of
https://github.com/OMGeeky/google-apis-rs.git
synced 2026-01-23 11:44:55 +01:00
feat(CLI): repeated required args
* Seem to work for docopt, mkdocs and code itself * mkdocs now show type of required params * some code which deals with converting elements to their target types is totally untested right now. Related to #77
This commit is contained in:
@@ -5,7 +5,7 @@
|
||||
from cli import (subcommand_md_filename, new_method_context, SPLIT_START, SPLIT_END, pretty, SCOPE_FLAG,
|
||||
mangle_subcommand, is_request_value_property, FIELD_SEP, PARAM_FLAG, UPLOAD_FLAG, docopt_mode,
|
||||
FILE_ARG, MIME_ARG, OUT_ARG, OUTPUT_FLAG, to_cli_schema, cli_schema_to_yaml, SchemaEntry,
|
||||
STRUCT_FLAG, field_to_value, CTYPE_ARRAY, CTYPE_MAP)
|
||||
STRUCT_FLAG, field_to_value, CTYPE_ARRAY, CTYPE_MAP, to_docopt_arg)
|
||||
|
||||
from copy import deepcopy
|
||||
|
||||
@@ -51,8 +51,11 @@ You can set the scope for this method like this: `${util.program_name()} --${SCO
|
||||
% if rprops:
|
||||
# Required Scalar ${len(rprops) > 1 and 'Arguments' or 'Argument'}
|
||||
% for p in rprops:
|
||||
* **<${mangle_subcommand(p.name)}\>**
|
||||
* **${to_docopt_arg(p) | xml_escape}** *(${p.type})*
|
||||
- ${p.get('description') or NO_DESC | xml_escape, indent_all_but_first_by(2)}
|
||||
% if p.get('repeated'):
|
||||
- This property can be specified one or more times
|
||||
% endif
|
||||
% endfor # each required property (which is not the request value)
|
||||
% endif # have required properties
|
||||
% if mc.request_value:
|
||||
|
||||
Reference in New Issue
Block a user