summaryrefslogtreecommitdiffstats
path: root/commands/Kconfig
diff options
context:
space:
mode:
authorHolger Schurig <holgerschurig@gmail.com>2014-05-13 10:28:53 +0200
committerSascha Hauer <s.hauer@pengutronix.de>2014-05-14 10:03:48 +0200
commit26a34100e88b707db00f0b66361f344177cdf4ff (patch)
treea2697e4300c94e39d43d8a80cf00a0332a83e254 /commands/Kconfig
parent6e3a969106fc84413f6ccef34fb78c0f8f9dd6ba (diff)
downloadbarebox-26a34100e88b707db00f0b66361f344177cdf4ff.tar.gz
barebox-26a34100e88b707db00f0b66361f344177cdf4ff.tar.xz
commands: HUSH_GETOPT -> CMD_GETOPT
* this compile option actually turns on a command, so name it accordingly * also move the Kconfig definition into commands/Kconfig, thus placing getopt into the "Shell scripting commands" section * while at it, improve Kconfig documention Signed-off-by: Holger Schurig <holgerschurig@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'commands/Kconfig')
-rw-r--r--commands/Kconfig15
1 files changed, 15 insertions, 0 deletions
diff --git a/commands/Kconfig b/commands/Kconfig
index 65bc2f64ec..2339f4e3a9 100644
--- a/commands/Kconfig
+++ b/commands/Kconfig
@@ -942,6 +942,21 @@ config CMD_FALSE
help
Do nothing, unsuccessfully
+config CMD_GETOPT
+ bool
+ depends on SHELL_HUSH
+ prompt "getopt"
+ help
+ Parse option arguments
+
+ Usage: getopt OPTSTRING VAR
+
+ OPTSTRING contains the option letters. Add a colon to an
+ options if this Option has a required argument or two colons
+ for an optional argument. The Current option is saved in
+ VAR, arguments are saved in $OPTARG. Any n-option arguments
+ can be accessed starting from $1.
+
config CMD_LET
tristate
prompt "let"