From b6b5ecc210d7e4044cefd83fb4e59dbe88aaef12 Mon Sep 17 00:00:00 2001 From: Sage Weil Date: Tue, 1 Jun 2021 14:43:47 -0400 Subject: [PATCH] mon/MonCommands: add -- seperator to example Signed-off-by: Sage Weil --- src/mon/MonCommands.h | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/mon/MonCommands.h b/src/mon/MonCommands.h index 2ca0d0e8f1c..df03ca4a8a8 100644 --- a/src/mon/MonCommands.h +++ b/src/mon/MonCommands.h @@ -77,7 +77,9 @@ * * COMMAND("auth add " * "name=entity,type=CephString " - * "name=caps,type=CephString,n=N,req=false", + * "name=caps,type=CephString,n=N,req=false " + * "-- " + * "name=some_option,type=CephString,req=false", * "add auth info for from input file, or random key " * "if no input given, and/or any caps specified in the command") * @@ -88,6 +90,12 @@ * enters auth add client.admin 'mon rwx' 'osd *'. The result will be a * JSON object like {"prefix":"auth add", "entity":"client.admin", * "caps":["mon rwx", "osd *"]}. + * + * The -- separates positional from non-positional (and, by implication, + * optional) arguments. Note that CephBool is assumed to be non-positional + * and will also implicitly mark that any following arguments are + * non-positional. + * * Note that * - string literals are accumulated into 'prefix' * - n=1 descriptors are given normal string or int object values -- 2.39.5