[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
emacs-27 32090a3: Improve documentation of streams in batch mode
From: |
Eli Zaretskii |
Subject: |
emacs-27 32090a3: Improve documentation of streams in batch mode |
Date: |
Sun, 6 Dec 2020 08:55:26 -0500 (EST) |
branch: emacs-27
commit 32090a3de4a32867aafeb905e5b134c72ec74175
Author: Eli Zaretskii <eliz@gnu.org>
Commit: Eli Zaretskii <eliz@gnu.org>
Improve documentation of streams in batch mode
* doc/lispref/os.texi (Batch Mode):
* doc/lispref/streams.texi (Input Streams, Output Streams): Better
documentation of I/O streams in batch mode, with more
cross-references.
---
doc/lispref/os.texi | 16 ++++++++--------
doc/lispref/streams.texi | 18 ++++++++++--------
2 files changed, 18 insertions(+), 16 deletions(-)
diff --git a/doc/lispref/os.texi b/doc/lispref/os.texi
index b31ab87..dad5d99 100644
--- a/doc/lispref/os.texi
+++ b/doc/lispref/os.texi
@@ -2609,14 +2609,14 @@ calls @var{function} with no arguments, or
@samp{--eval=@var{form}}.
Any Lisp program output that would normally go to the echo area,
either using @code{message}, or using @code{prin1}, etc., with
-@code{t} as the stream, goes instead to Emacs's standard descriptors
-when in batch mode: @code{message} writes to the standard error
-descriptor, while @code{prin1} and other print functions write to the
-standard output. Similarly, input that would normally come from the
-minibuffer is read from the standard input descriptor. Thus, Emacs
-behaves much like a noninteractive application program. (The echo
-area output that Emacs itself normally generates, such as command
-echoing, is suppressed entirely.)
+@code{t} as the stream (@pxref{Output Streams}), goes instead to
+Emacs's standard descriptors when in batch mode: @code{message} writes
+to the standard error descriptor, while @code{prin1} and other print
+functions write to the standard output. Similarly, input that would
+normally come from the minibuffer is read from the standard input
+descriptor. Thus, Emacs behaves much like a noninteractive
+application program. (The echo area output that Emacs itself normally
+generates, such as command echoing, is suppressed entirely.)
Non-ASCII text written to the standard output or error descriptors is
by default encoded using @code{locale-coding-system} (@pxref{Locales})
diff --git a/doc/lispref/streams.texi b/doc/lispref/streams.texi
index 2cd61ad..f27eb0a 100644
--- a/doc/lispref/streams.texi
+++ b/doc/lispref/streams.texi
@@ -123,13 +123,13 @@ came from. In this case, it makes no difference what
value
@code{t} used as a stream means that the input is read from the
minibuffer. In fact, the minibuffer is invoked once and the text
given by the user is made into a string that is then used as the
-input stream. If Emacs is running in batch mode, standard input is used
-instead of the minibuffer. For example,
+input stream. If Emacs is running in batch mode (@pxref{Batch Mode}),
+standard input is used instead of the minibuffer. For example,
@example
(message "%s" (read t))
@end example
-will read a Lisp expression from standard input and print the result
-to standard output.
+will in batch mode read a Lisp expression from standard input and
+print the result to standard output.
@item @code{nil}
@cindex @code{nil} input stream
@@ -392,13 +392,15 @@ is responsible for storing the characters wherever you
want to put them.
@item @code{t}
@cindex @code{t} output stream
-The output characters are displayed in the echo area.
+The output characters are displayed in the echo area. If Emacs is
+running in batch mode (@pxref{Batch Mode}), the output is written to
+the standard output descriptor instead.
@item @code{nil}
@cindex @code{nil} output stream
-@code{nil} specified as an output stream means to use the value of
-@code{standard-output} instead; that value is the @dfn{default output
-stream}, and must not be @code{nil}.
+@code{nil} specified as an output stream means to use the value of the
+@code{standard-output} variable instead; that value is the
+@dfn{default output stream}, and must not be @code{nil}.
@item @var{symbol}
A symbol as output stream is equivalent to the symbol's function
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- emacs-27 32090a3: Improve documentation of streams in batch mode,
Eli Zaretskii <=