diff options
author | Rich Salz <rsalz@akamai.com> | 2019-11-08 06:08:30 +1000 |
---|---|---|
committer | Pauli <paul.dale@oracle.com> | 2019-11-08 06:08:30 +1000 |
commit | 5388f9862d9aaf3c7cf7a70c1e36e7e983c26cfc (patch) | |
tree | bda368ec4d8855ac5d3e2a31648769a5dabfaac9 /apps/include | |
parent | ab14d2af5386897eba8307c9f3220a6d775c0898 (diff) |
Add "sections" to -help output
Remove "Valid options" label, since all commands have sections (and
[almost] always the first one is "General options").
Have "list --options" ignore section headers
Reformat ts's additional help
Add output section
Reviewed-by: Tomas Mraz <tmraz@fedoraproject.org>
Reviewed-by: Paul Dale <paul.dale@oracle.com>
(Merged from https://github.com/openssl/openssl/pull/9953)
Diffstat (limited to 'apps/include')
-rw-r--r-- | apps/include/opt.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/apps/include/opt.h b/apps/include/opt.h index 5493563004..59bfdcfefb 100644 --- a/apps/include/opt.h +++ b/apps/include/opt.h @@ -32,6 +32,7 @@ OPT_V__LAST # define OPT_V_OPTIONS \ + OPT_SECTION("Validation"), \ { "policy", OPT_V_POLICY, 's', "adds policy to the acceptable policy set"}, \ { "purpose", OPT_V_PURPOSE, 's', \ "certificate chain purpose"}, \ @@ -124,6 +125,7 @@ OPT_X__LAST # define OPT_X_OPTIONS \ + OPT_SECTION("Extended certificate"), \ { "xkey", OPT_X_KEY, '<', "key for Extended certificates"}, \ { "xcert", OPT_X_CERT, '<', "cert for Extended certificates"}, \ { "xchain", OPT_X_CHAIN, '<', "chain for Extended certificates"}, \ @@ -161,6 +163,7 @@ OPT_S_NO_RENEGOTIATION, OPT_S_NO_MIDDLEBOX, OPT_S__LAST # define OPT_S_OPTIONS \ + OPT_SECTION("TLS/SSL"), \ {"no_ssl3", OPT_S_NOSSL3, '-',"Just disable SSLv3" }, \ {"no_tls1", OPT_S_NOTLS1, '-', "Just disable TLSv1"}, \ {"no_tls1_1", OPT_S_NOTLS1_1, '-', "Just disable TLSv1.1" }, \ @@ -254,6 +257,7 @@ OPT_R__FIRST=1500, OPT_R_RAND, OPT_R_WRITERAND, OPT_R__LAST # define OPT_R_OPTIONS \ + OPT_SECTION("Random state"), \ {"rand", OPT_R_RAND, 's', "Load the file(s) into the random number generator"}, \ {"writerand", OPT_R_WRITERAND, '>', "Write random data to the specified file"} @@ -309,7 +313,7 @@ typedef struct string_int_pair_st { OPT_FMT_TEXT | OPT_FMT_HTTP | OPT_FMT_PVK) /* Divide options into sections when displaying usage */ -#define OPT_SECTION(sec) {OPT_SECTION_STR, 1, '-', sec " options:\n"} +#define OPT_SECTION(sec) { OPT_SECTION_STR, 1, '-', sec " options:\n" } char *opt_progname(const char *argv0); char *opt_getprog(void); |