From: Justin Pettit Date: Thu, 16 Apr 2015 22:03:42 +0000 (-0700) Subject: ovn-nbctl: Bring usage output more in line with other utils. X-Git-Tag: v2.5.0~1127 X-Git-Url: http://git.cascardo.eti.br/?a=commitdiff_plain;h=a367622aea312ce5c6e219212af08d5ed20ca61c;p=cascardo%2Fovs.git ovn-nbctl: Bring usage output more in line with other utils. Signed-off-by: Justin Pettit --- diff --git a/ovn/ovn-nbctl.c b/ovn/ovn-nbctl.c index 7021aa6f0..b00d7b1d1 100644 --- a/ovn/ovn-nbctl.c +++ b/ovn/ovn-nbctl.c @@ -47,28 +47,28 @@ usage(void) %s: OVN northbound DB management utility\n\ usage: %s [OPTIONS] COMMAND [ARG...]\n\ \n\ -Logical Switch Commands:\n\ - lswitch-add [name] Create a logical switch\n\ - lswitch-del Delete a logical switch\n\ - lswitch-list List configured logical switches\n\ - lswitch-set-external-id [value]\n\ - Set or delete an external:id on a logical switch\n\ - lswitch-get-external-id [key]\n\ - List one or all external:ids set on a switch\n\ +Logical switch commands:\n\ + lswitch-add [LSWITCH] create a logical switch named LSWITCH\n\ + lswitch-del LSWITCH delete LSWITCH and all its ports\n\ + lswitch-list print the names of all logical switches\n\ + lswitch-set-external-id LSWITCH KEY [VALUE]\n\ + set or delete an external-id on LSWITCH\n\ + lswitch-get-external-id LSWITCH [KEY]\n\ + list one or all external-ids on LSWITCH\n\ \n\ -Logical Port Commands:\n\ - lport-add Create a logical port on a logical switch\n\ - lport-del Delete a logical port (by name or UUID)\n\ - lport-list List ports on a logical switch\n\ - lport-set-external-id [value]\n\ - Set or delete an external:id on a logical port\n\ - lport-get-external-id [key]\n\ - List one or all external:ids set on a port\n\ - lport-set-macs [MAC] [MAC] [...]\n\ - Set MAC addresses for the logical port. Specify\n\ - more than one using additional arguments.\n\ - lport-get-macs Get a list of MAC addresses on the port.\n\ - lport-get-up Get state of the port ('up' or 'down').\n\ +Logical port commands:\n\ + lport-add LSWITCH LPORT add logical port LPORT on LSWITCH\n\ + lport-del LPORT delete LPORT from its attached switch\n\ + lport-list LSWITCH print the names of all logical ports on LSWITCH\n\ + lport-set-external-id LPORT KEY [VALUE]\n\ + set or delete an external-id on LPORT\n\ + lport-get-external-id LPORT [KEY]\n\ + list one or all external-ids on LPORT\n\ + lport-set-macs LPORT [MAC] [MAC] [...]\n\ + set MAC addresses for LPORT. Specify more\n\ + than one using additional arguments.\n\ + lport-get-macs LPORT get a list of MAC addresses on LPORT\n\ + lport-get-up LPORT get state of LPORT ('up' or 'down')\n\ \n\ Options:\n\ --db=DATABASE connect to DATABASE\n\ @@ -482,14 +482,14 @@ parse_options(int argc, char *argv[]) static const struct ovs_cmdl_command all_commands[] = { { .name = "lswitch-add", - .usage = "[lswitch]", + .usage = "[LSWITCH]", .min_args = 0, .max_args = 1, .handler = do_lswitch_add, }, { .name = "lswitch-del", - .usage = "", + .usage = "LSWITCH", .min_args = 1, .max_args = 1, .handler = do_lswitch_del, @@ -503,56 +503,56 @@ static const struct ovs_cmdl_command all_commands[] = { }, { .name = "lswitch-set-external-id", - .usage = " [value]", + .usage = "LSWITCH KEY [VALUE]", .min_args = 2, .max_args = 3, .handler = do_lswitch_set_external_id, }, { .name = "lswitch-get-external-id", - .usage = " [key]", + .usage = "LSWITCH [KEY]", .min_args = 1, .max_args = 2, .handler = do_lswitch_get_external_id, }, { .name = "lport-add", - .usage = " ", + .usage = "LSWITCH LPORT", .min_args = 2, .max_args = 2, .handler = do_lport_add, }, { .name = "lport-del", - .usage = "", + .usage = "LPORT", .min_args = 1, .max_args = 1, .handler = do_lport_del, }, { .name = "lport-list", - .usage = "", + .usage = "LSWITCH", .min_args = 1, .max_args = 1, .handler = do_lport_list, }, { .name = "lport-set-external-id", - .usage = " [value]", + .usage = "LPORT KEY [VALUE]", .min_args = 2, .max_args = 3, .handler = do_lport_set_external_id, }, { .name = "lport-get-external-id", - .usage = " [key]", + .usage = "LPORT [KEY]", .min_args = 1, .max_args = 2, .handler = do_lport_get_external_id, }, { .name = "lport-set-macs", - .usage = " [MAC] [MAC] [...]", + .usage = "LPORT [MAC] [MAC] [...]", .min_args = 1, /* Accept however many arguments the system will allow. */ .max_args = INT_MAX, @@ -560,14 +560,14 @@ static const struct ovs_cmdl_command all_commands[] = { }, { .name = "lport-get-macs", - .usage = "", + .usage = "LPORT", .min_args = 1, .max_args = 1, .handler = do_lport_get_macs, }, { .name = "lport-get-up", - .usage = "", + .usage = "LPORT", .min_args = 1, .max_args = 1, .handler = do_lport_get_up,