mirror of
https://github.com/ElementsProject/lightning.git
synced 2025-02-21 14:24:09 +01:00
lightning-cli: use human_readable for help messages (unescapes \n for us).
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Changelog-Changed: lightning-cli: `help` messages using new-lines is now printed properly, enhancing readability and consistency.
This commit is contained in:
parent
ca0c9e63ad
commit
44093f09c3
1 changed files with 2 additions and 2 deletions
|
@ -197,8 +197,8 @@ static void human_help(char *buffer, const jsmntok_t *result)
|
|||
for (i = 0; i < tal_count(help); i++) {
|
||||
const jsmntok_t *command;
|
||||
command = json_get_member(buffer, help[i], "command");
|
||||
printf("%.*s\n\n",
|
||||
command->end - command->start, buffer + command->start);
|
||||
human_readable(buffer, command, '\n');
|
||||
printf("\n");
|
||||
}
|
||||
tal_free(help);
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue