aboutsummaryrefslogtreecommitdiff
path: root/json-rpc-shell.c
diff options
context:
space:
mode:
authorPřemysl Eric Janouch <p@janouch.name>2020-09-04 23:33:17 +0200
committerPřemysl Eric Janouch <p@janouch.name>2020-09-05 03:51:36 +0200
commit2962a644da2faef651e5878090f2357e4f0fd13b (patch)
tree2341fc3bcc6a0088c7533f4ed1d7b738e8526fa9 /json-rpc-shell.c
parent6f5ef30293c3a31d86e2ba6bec7ae0d8ef9cafc8 (diff)
downloadjson-rpc-shell-2962a644da2faef651e5878090f2357e4f0fd13b.tar.gz
json-rpc-shell-2962a644da2faef651e5878090f2357e4f0fd13b.tar.xz
json-rpc-shell-2962a644da2faef651e5878090f2357e4f0fd13b.zip
Write a nice new man page in AsciiDoc
Taking some preliminary steps for inclusion in Linux distributions. The help message has been slightly improved and the README extended, with part of it now residing in the man page. One less GNU dependency, for what it's worth.
Diffstat (limited to 'json-rpc-shell.c')
-rw-r--r--json-rpc-shell.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/json-rpc-shell.c b/json-rpc-shell.c
index dcd0a5e..10105cd 100644
--- a/json-rpc-shell.c
+++ b/json-rpc-shell.c
@@ -3339,13 +3339,16 @@ parse_program_arguments (struct app_context *ctx, int argc, char **argv,
static const struct opt opts[] =
{
{ 'd', "debug", NULL, 0, "run in debug mode" },
- { 'h', "help", NULL, 0, "display this help and exit" },
+ { 'h', "help", NULL, 0, "display this help message and exit" },
{ 'V', "version", NULL, 0, "output version information and exit" },
+ // TODO: consider making this the default and instead adding
+ // an option to accept JSON null as an id.
{ 'a', "auto-id", NULL, 0, "automatic `id' fields" },
{ 'o', "origin", "O", 0, "set the HTTP Origin header" },
+ // TODO: consider inverting this to -c/--compact-output
{ 'p', "pretty", NULL, 0, "pretty-print the responses" },
{ 't', "trust-all", NULL, 0, "don't care about SSL/TLS certificates" },
- { 'v', "verbose", NULL, 0, "print the request before sending" },
+ { 'v', "verbose", NULL, 0, "print raw requests and responses" },
{ 'c', "color", "WHEN", OPT_LONG_ONLY,
"colorize output: never, always, or auto" },
{ 'w', "write-default-cfg", "FILENAME",
@@ -3355,7 +3358,7 @@ parse_program_arguments (struct app_context *ctx, int argc, char **argv,
};
struct opt_handler oh = opt_handler_make (argc, argv, opts,
- "ENDPOINT", "Simple JSON-RPC shell.");
+ "ENDPOINT", "A simple JSON-RPC 2.0 shell.");
int c;
while ((c = opt_handler_get (&oh)) != -1)