apps/nshlib: (1) NSH prompt string is now configurable. nsh> is still the default. (2) Increase the default configuration for the maximum number of command line arguments to 7 (CONFIG_NSH_MAXARGUMENTS). This is needed for 'mount' with the -o option.

This commit is contained in:
Xiang Xiao
2018-08-23 07:34:30 -06:00
committed by Gregory Nutt
parent 8116d10da3
commit dbf152cbeb
3 changed files with 10 additions and 17 deletions

View File

@@ -464,7 +464,7 @@
/* This is the maximum number of arguments that will be accepted for a
* command. Here we attempt to select the smallest number possible depending
* upon the of commands that are available. Most commands use six or fewer
* upon the of commands that are available. Most commands use seven or fewer
* arguments, but there are a few that require more.
*
* This value is also configurable with CONFIG_NSH_MAXARGUMENTS. This
@@ -472,10 +472,6 @@
* commands that require more commands than NSH is aware of.
*/
#ifndef CONFIG_NSH_MAXARGUMENTS
# define CONFIG_NSH_MAXARGUMENTS 6
#endif
#if CONFIG_NSH_MAXARGUMENTS < 11
# if defined(CONFIG_NET) && !defined(CONFIG_NSH_DISABLE_IFCONFIG)
# undef CONFIG_NSH_MAXARGUMENTS
@@ -483,15 +479,6 @@
# endif
#endif
#if CONFIG_NSH_MAXARGUMENTS < 7
# if defined(CONFIG_NET_UDP) && CONFIG_NFILE_DESCRIPTORS > 0
# if !defined(CONFIG_NSH_DISABLE_GET) || !defined(CONFIG_NSH_DISABLE_PUT)
# undef CONFIG_NSH_MAXARGUMENTS
# define CONFIG_NSH_MAXARGUMENTS 7
# endif
# endif
#endif
/* Argument list size
*
* argv[0]: The command name.