From 565e25502ca5e3c94fb5a75b9dde5c54e2a07597 Mon Sep 17 00:00:00 2001 From: Alexandre Duret-Lutz Date: Wed, 16 May 2018 17:18:48 +0200 Subject: [PATCH] bin: stop supporting the hidden --usage It's not used anywhere, not documented, and its output is slightly broken with options that are too long. * bin/common_setup.cc: Remove --usage support. --- bin/common_setup.cc | 6 ------ 1 file changed, 6 deletions(-) diff --git a/bin/common_setup.cc b/bin/common_setup.cc index f82c3e357..cb953b9ee 100644 --- a/bin/common_setup.cc +++ b/bin/common_setup.cc @@ -140,8 +140,6 @@ static const argp_option options_hidden[] = { "version", OPT_VERSION, nullptr, OPTION_HIDDEN, "print program version", -1 }, { "help", OPT_HELP, nullptr, OPTION_HIDDEN, "print this help", -1 }, - // We support this option just in case, but we don't advertise it. - { "usage", OPT_USAGE, nullptr, OPTION_HIDDEN, "show short usage", -1 }, { nullptr, 0, nullptr, 0, nullptr, 0 } }; @@ -154,10 +152,6 @@ parse_opt_misc(int key, char*, struct argp_state* state) case OPT_HELP: argp_state_help(state, state->out_stream, ARGP_HELP_STD_HELP); break; - case OPT_USAGE: - argp_state_help(state, state->out_stream, - ARGP_HELP_USAGE | ARGP_HELP_EXIT_OK); - break; case OPT_VERSION: display_version(state->out_stream, state); exit(0);