Xiang Xiao
1ee948e0c8
Include assert.h for DEBUGASSERT caller
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-05-24 12:34:37 +09:00
Xiang Xiao
ecae66fe59
Replace all CONFIG_NFILE_STREAMS with CONFIG_FILE_STREAM
...
follow up the kernel side change
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: Ic27ad65d7cc2ea570921e0c17098dcb6bfe1893a
2020-09-11 17:57:58 +08:00
Xiang Xiao
9d80399bd5
nsh: Accept the command line arguments like sh
...
Usage: nsh [<script-path>|-c <command>]
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: Ifb76b27e7fd09d26b1f6e48c391fed0972018041
2020-08-19 14:32:53 -07:00
Xiang Xiao
650b58d6b2
nshlib: Fix nxstyle warning
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-04-19 08:07:06 -06:00
Xiang Xiao
9ab5e2ff45
nshlib: Add login argument to nsh_session for controling the login process
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-04-19 08:07:06 -06:00
Xiang Xiao
857158451b
Unify the void cast usage
...
1.Remove void cast for function because many place ignore the returned value witout cast
2.Replace void cast for variable with UNUSED macro
Change-Id: Ie644129a563244a6397036789c4c3ea83c4e9b09
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-01-02 23:21:01 +08:00
Dave Marples
dbd4e67241
apps/system/cle/cle.c: This commit modifies the cle to use the streams file interface more consistently and has removed the observed race conditions. It was previously a mix of streams and fileio. It also simplifies the VT100 cursor position handling.
2019-11-04 11:35:18 -06:00
Dave Marples
b4134a674d
nshlib/ and system/cle: Add basic color support to the CLE editor.
2019-10-12 00:47:29 +08:00
Valmantas Paliksa
5cad41c973
apps/nshlib: Fix all places where cle() and readline() are used. readline() returns EOF on a failure. cle() returns a negated errno value. Checking only for EOF causes failues to be missed (and infinite loops ensuing).
2019-05-21 08:43:09 -06:00
GregoryN
3bf4b6d245
Merged altconsole into master
2018-12-08 18:53:54 -06:00
Gregory Nutt
c5edf40542
apps/examples/udpblaster: Add option to use poll() on output (only). Also picks up some fixes to various typographical errors.
2018-09-14 06:59:23 -06:00
Gregory Nutt
8cfa1dbd3b
The previous commit was reverted. My concern was misplaced: There is a guard boolean to prevent running the init script more than once. This comment just restores some of the good cosmetic changes that were included in the reverted commit.
2016-08-25 14:28:25 -06:00
Gregory Nutt
4eda22b4db
Revert "This commit adds nsh_consolechild(). I noticed that there are several examples that call nsh_consolemain.c to create to create a new NSH session. That will not always work because nsh_consolemain() performs the one-time initialization needed by the NSH library: Mounting, reading, and running the start-up script, configuring USB tracing. Some of those actions will cause failures if attempted twice."
...
This reverts commit 4d364d836a
.
2016-08-25 14:19:36 -06:00
Gregory Nutt
4d364d836a
This commit adds nsh_consolechild(). I noticed that there are several examples that call nsh_consolemain.c to create to create a new NSH session. That will not always work because nsh_consolemain() performs the one-time initialization needed by the NSH library: Mounting, reading, and running the start-up script, configuring USB tracing. Some of those actions will cause failures if attempted twice.
...
Here are some offenders: examples/cc3000/shell.c, examples/nsh/nsh_main.c, examples/nxterm/nxterm_main.c, and examples/pty_test/pty_test.c. It is possible that for some of those, that represents the first call to nsh_consolemain(). But probably not.
To give other initialization options, I added nsh_consolechild() which is identical to nsh_consolemain() other than it omits all of the one-time initialization. Of course, you would not get the result that you wanted if nsh_consolechild() were called without nsh_consolemain().
2016-08-25 14:14:23 -06:00
Sebastien Lorquet
2cbad44f1d
This is the Pokemon patch to change all includes fronm <apps/bla/bla.h> to "bla/bla.h"
2016-07-11 10:11:18 -06:00
Gregory Nutt
cd741c82cf
apps/include: Move all header files associated with modules in apps/system to apps/include/system
2016-07-01 06:48:22 -06:00
Gregory Nutt
93d9d5e4ca
apps/nshlib: All NSH sessions may now be protected with passwords stored in the encrypted /etc/passwd file
2016-01-20 14:42:39 -06:00
Gregory Nutt
3dad8a29a2
NSH now supports an MOTD string that will be presented after the greeting
2016-01-20 11:18:08 -06:00
Gregory Nutt
82d71bb439
Add an EMACS-like command line editor that can be used wit NSH
2014-02-02 10:25:53 -06:00
Gregory Nutt
c4e46f5b62
Changes to NSH and readline to permit NSH to work on a platform with no file system
2013-09-30 11:34:04 -06:00
patacongo
142c478747
Fix a readline bug. If a NUL is received, it would return end-of-file
...
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@5633 42af7a65-404d-4744-a932-0658087f49c3
2013-02-10 00:46:27 +00:00
patacongo
978d3212ff
Add support for a login script (in addition to the init script); Add logic so that a USB console session can connect and reconnect to the USB serial device
...
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@5582 42af7a65-404d-4744-a932-0658087f49c3
2013-01-29 22:11:04 +00:00