Added interactive shell prompt escape sequences.

git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@299581 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
Daniel Egeberg 2010-05-21 14:36:06 +00:00
parent 20b6ea33c7
commit 89a79ec8c9

View file

@ -1503,6 +1503,52 @@ php >
]]>
</programlisting>
</example>
<para>
The <parameter>cli.prompt</parameter> setting supports a few escape
sequences:
<table>
<title><parameter>cli.prompt</parameter> escape sequences</title>
<tgroup cols="2">
<thead>
<row>
<entry>Sequence:</entry>
<entry>Description:</entry>
</row>
</thead>
<tbody>
<row>
<entry><literal>\e</literal></entry>
<entry>
Used for adding colors to the prompt. An example could be
<literal>\e[032m\v \e[031m\b \e[34m\> \e[0m</literal>
</entry>
</row>
<row>
<entry><literal>\v</literal></entry>
<entry>The PHP version.</entry>
</row>
<row>
<entry><literal>\b</literal></entry>
<entry>
Indicates which block PHP is in. For instance <literal>/*</literal> to
indicate being inside a multi-line comment. The outer scope is denoted by
<literal>php</literal>.
</entry>
</row>
<row>
<entry><literal>\&gt;</literal></entry>
<entry>
Indicates the prompt character. By default this is
<literal>&gt;</literal>, but changes when the shell is inside an
unterminated block or string. Possible characters are: <literal>' " {
( &gt;</literal>
</entry>
</row>
</tbody>
</tgroup>
</table>
</para>
-->
<note>