From 69260adb38c7f5f1602f045c16e9f797038cff1e Mon Sep 17 00:00:00 2001 From: renepickhardt Date: Fri, 19 Jan 2018 11:09:54 +0100 Subject: [PATCH] quickfixing issue #662 to make CLI more userfriendly for inexperienced users (#663) * making the cli more user friendly for inexperienced users #662 providing a quickfix for https://github.com/ElementsProject/lightning/issues/662 Basically I extended the ./lighting-cli --help message to at least state that one should use ./lighting-cli help, and added a hint to cli/lighting-cli help to the README Closes: #662 --- README.md | 3 +++ cli/lightning-cli.c | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index dd088bf33..b5fcb8c61 100644 --- a/README.md +++ b/README.md @@ -57,6 +57,9 @@ You can start `lightningd` with the following command: lightningd/lightningd --network=testnet --log-level=debug ``` +### Listing all commands: +`cli/lighting-cli help` will print a table of the API and lists the following commands + ### Opening a channel on the Bitcoin testnet First you need to transfer some funds to `lightningd` so that it can open a channel: diff --git a/cli/lightning-cli.c b/cli/lightning-cli.c index 584ba7dae..4cc8fb763 100644 --- a/cli/lightning-cli.c +++ b/cli/lightning-cli.c @@ -67,7 +67,7 @@ int main(int argc, char *argv[]) configdir_register_opts(ctx, &lightning_dir, &rpc_filename); opt_register_noarg("--help|-h", opt_usage_and_exit, - " [...]", "Show this message"); + " [...]", "Show this message\t use the command help (without hyphen) to get a list of all commands"); opt_register_version(); opt_early_parse(argc, argv, opt_log_stderr_exit);