diff options
author | Robert Schwebel <r.schwebel@pengutronix.de> | 2010-12-10 21:49:50 +0100 |
---|---|---|
committer | Robert Schwebel <r.schwebel@pengutronix.de> | 2010-12-17 21:28:40 +0100 |
commit | 63a4fea525d139675c116299b2281b5cf4fd0e27 (patch) | |
tree | 43b807b6739144eeb0ca94d12aacce8b95a27742 | |
parent | 7d94f0e34830e6e202621d0c7e8088e004f4e1e2 (diff) | |
download | barebox-63a4fea525d139675c116299b2281b5cf4fd0e27.tar.gz barebox-63a4fea525d139675c116299b2281b5cf4fd0e27.tar.xz |
doc: add documentation for 'test' command
Signed-off-by: Robert Schwebel <r.schwebel@pengutronix.de>
-rw-r--r-- | Documentation/commands.dox | 2 | ||||
-rw-r--r-- | commands/test.c | 16 |
2 files changed, 11 insertions, 7 deletions
diff --git a/Documentation/commands.dox b/Documentation/commands.dox index 45947e93..0293edce 100644 --- a/Documentation/commands.dox +++ b/Documentation/commands.dox @@ -95,7 +95,7 @@ available in @a Barebox: @li @subpage sh @li @subpage sleep_command @li @subpage source -@li @subpage test +@li @subpage test_command @li @subpage timeout_command @li @subpage true_command @li @subpage tftp_command diff --git a/commands/test.c b/commands/test.c index 4af35156..89a17648 100644 --- a/commands/test.c +++ b/commands/test.c @@ -222,16 +222,20 @@ out: static const char *test_aliases[] = { "[", NULL}; -static const __maybe_unused char cmd_test_help[] = -"Usage: test [OPTIONS]\n" -"options: !, =, !=, -eq, -ne, -ge, -gt, -le, -lt, -o, -a, -z, -n, -d, -e, -f\n" -"see 'man test' on your PC for more information.\n"; +BAREBOX_CMD_HELP_START(test) +BAREBOX_CMD_HELP_USAGE("test [OPTIONS]\n") +BAREBOX_CMD_HELP_SHORT("!, =, !=, -eq, -ne, -ge, -gt, -le, -lt, -o, -a, -z, -n, -d, -e, -f\n") +BAREBOX_CMD_HELP_END -static const __maybe_unused char cmd_test_usage[] = "minimal test like /bin/sh"; +/** + * @page test_command + +See 'man test' on your PC for more information. + */ BAREBOX_CMD_START(test) .aliases = test_aliases, .cmd = do_test, - .usage = cmd_test_usage, + .usage = "test for a condition", BAREBOX_CMD_HELP(cmd_test_help) BAREBOX_CMD_END |