doc: refine documentation for external-process

Signed-off-by: Daniel Kochmański <daniel@turtleware.eu>
This commit is contained in:
Daniel Kochmański 2015-08-12 11:21:27 +02:00
parent f07fbf1493
commit fc976a96ff
2 changed files with 50 additions and 4 deletions

View file

@ -352,13 +352,14 @@ ls [--help | -?] filename*
<listitem><para>process output stream</para></listitem>
</varlistentry>
<varlistentry>
<term><replaceable>ERROR</replaceable></term>
<term><replaceable>ERROR-STREAM</replaceable></term>
<listitem><para>process error stream</para></listitem>
</varlistentry>
<varlistentry>
<term><replaceable>%STATUS</replaceable></term>
<listitem><para>either <symbol>:RUNNING</symbol> or
<symbol>:EXITED</symbol></para></listitem>
<term><replaceable>%STATUS</replaceable></term> <listitem><para>either
<symbol>:RUNNING</symbol>, <symbol>:STOPPED</symbol>,
<symbol>:SIGNALED</symbol>, <symbol>:EXITED</symbol></para></listitem>,
<symbol>:ERROR</symbol> or <symbol>:ABORT</symbol>
</varlistentry>
<varlistentry>
<term><replaceable>%CODE</replaceable></term>
@ -373,6 +374,34 @@ ls [--help | -?] filename*
process id, communication streams, runtime status and exit code. It is
returned as third value of <xref linkend="ref.run-program"/>.</para>
</refsect1>
</refentry>
<!-- ====================================================================== -->
<!-- EXT:EXTERNAL-PROCESS-STATUS -->
<!-- ====================================================================== -->
<refentry xml:id="ref.external-process-status">
<refnamediv>
<refname><function>ext:external-process-status</function></refname>
<refpurpose>Check status of <xref
linkend="ref.external-process"/>.</refpurpose>
</refnamediv>
<refsynopsisdiv>
<title>Function</title>
<funcsynopsis>
<funcprototype>
<funcdef>ext:external-process-status</funcdef>
<paramdef><parameter>external-process</parameter></paramdef>
</funcprototype>
</funcsynopsis>
<refsect1>
<title>Description</title>
<para>Checks status of external-process. Returns it's current status, and
if exited - <symbol>EXIT-CODE</symbol> as second value.</para>
</refsect1>
</refsynopsisdiv>
</refentry>
<!-- ======================================================================

View file

@ -3059,6 +3059,23 @@ Returns T if X is a symbol; NIL otherwise.")
(docfun ext:system function (string) "
Executes a Shell command as if STRING is an input to the Shell.")
(docfun ext:run-program function (command argv &key
(input :stream)
(output :stream)
(error :output)
(wait t) environ
if-input-does-no-exist
(if-output-exists :error)
(if-error-exists :error)
(external-format :default)) "
Creates external process with COMMAND given args ARGV, where INPUT,
OUTPUT and ERROR might be :STREAM, T, NIL, pathname designator or
stream (gray streams doesn't work). ERROR might be also :OUTPUT. If
WAIT is T, then process is ran asynchronously.
Returns two-way stream for communication, process status (or exit
code, depending on wait parameter) and EXTERNAL-PROCESS structure.")
(doctype t "
The type T is a supertype of every type. Every object belongs to this type.")