unix: Add exit and paste-mode hints to shell startup banner.

Thanks to @nyov for the initial patch.
pull/1505/head
Damien George 2015-10-12 00:19:00 +01:00
rodzic fccbe9aa4d
commit 3aa7dd23c9
5 zmienionych plików z 6 dodań i 1 usunięć

Wyświetl plik

@ -1,4 +1,5 @@
MicroPython \.\+ version
Use \.\+
>>> # basic REPL tests
>>> print(1)
1

Wyświetl plik

@ -1,4 +1,5 @@
MicroPython \.\+ version
Use \.\+
>>> # check REPL allows to continue input
>>> 1 \\\\
... + 2

Wyświetl plik

@ -1,4 +1,5 @@
MicroPython \.\+ version
Use \.\+
>>> # REPL tests of GNU-ish readline navigation
>>> # history buffer navigation
>>> 1

Wyświetl plik

@ -1,4 +1,5 @@
MicroPython \.\+ version
Use \.\+
>>> # Check for emacs keys in REPL
>>> t = \.\+
>>> t == 2

Wyświetl plik

@ -153,7 +153,8 @@ STATIC char *strjoin(const char *s1, int sep_char, const char *s2) {
#endif
STATIC int do_repl(void) {
mp_hal_stdout_tx_str("MicroPython " MICROPY_GIT_TAG " on " MICROPY_BUILD_DATE "; " MICROPY_PY_SYS_PLATFORM " version\n");
mp_hal_stdout_tx_str("MicroPython " MICROPY_GIT_TAG " on " MICROPY_BUILD_DATE "; "
MICROPY_PY_SYS_PLATFORM " version\nUse CTRL-D to exit, CTRL-E for paste mode\n");
#if MICROPY_USE_READLINE == 1