diff options
Diffstat (limited to 'commands/timeout.c')
-rw-r--r-- | commands/timeout.c | 20 |
1 files changed, 11 insertions, 9 deletions
diff --git a/commands/timeout.c b/commands/timeout.c index 0e81583701..feca7140d5 100644 --- a/commands/timeout.c +++ b/commands/timeout.c @@ -102,18 +102,20 @@ out: return ret; } -static const __maybe_unused char cmd_timeout_help[] = -"Usage: timeout [OPTION]... <timeout>\n" -"Wait <timeout> seconds for a timeout. Return 1 if the user intervented\n" -"or 0 if a timeout occured\n" -" -a interrupt on any key\n" -" -c interrupt on ctrl-c\n" -" -r interrupt on return\n" -" -s silent mode\n"; +BAREBOX_CMD_HELP_START(timeout) +BAREBOX_CMD_HELP_TEXT("Wait SECONDS for a timeout. Return 1 if the user intervented.") +BAREBOX_CMD_HELP_TEXT("") +BAREBOX_CMD_HELP_TEXT("Options:") +BAREBOX_CMD_HELP_OPT("-a", "interrupt on any key") +BAREBOX_CMD_HELP_OPT("-c", "interrupt on Ctrl-C") +BAREBOX_CMD_HELP_OPT("-r", "interrupt on RETURN") +BAREBOX_CMD_HELP_OPT("-s", "silent mode") +BAREBOX_CMD_HELP_END BAREBOX_CMD_START(timeout) .cmd = do_timeout, - .usage = "wait for a specified timeout", + BAREBOX_CMD_DESC("wait for a specified timeout") + BAREBOX_CMD_OPTS("[-acrs] SECONDS") BAREBOX_CMD_GROUP(CMD_GRP_CONSOLE) BAREBOX_CMD_HELP(cmd_timeout_help) BAREBOX_CMD_END |