Questo plugin consente di formattare il testo specificato come se fosse la console di linux.
Sito: http://www.dokuwiki.org/plugin:cli
This plugins brings a Command Line Interface formatter to DokuWiki allowing you to format the output of a transcript say for a user manual or on-line tutorial. It is designed to work with the output of a standard Unix Bash Shell, but should be suitable to document other kinds of CLI interaction, e.g. Windows Command Window, Python and Ruby, Matlab, etc.
The assumptions made are
A key design feature is that it should be possible to display a CLI transcript (e.g. output from a history file or copy of text from a console window) for display with the mimumum of additional markup.
It is possible to adjust the style of the display using a style sheet. For details refer to style.css.
A similar feature is to be found in MoinMoin Wiki and TiddlyWiki. The styles are based on those developed for the UNIX Tutorial for Beginners by Michael Stonebank. The plugin and its documentation are based on lessons learned from the Plugin Tutorial and Christopher Smith's implementation and documentation of the boxes plugin.
Several improvements suggested by Stephane Chazelas and Andy Webber.
A simple Bash Shell interaction:
<cli> user@host:~/somedir $ ls # List current directory conf lang README screen.gif ui info.txt manager.dat renderer.php syntax.php user@host:~/somedir $ </cli>
Should be rendered:
<pre class="cli"> <span class="cli_prompt">user@host:~/somedir $</span> <span class="cli_command">ls</span> <span class="cli_comment"># List current directory</span> <span class="cli_output">conf lang README screen.gif ui</span> <span class="cli_output">info.txt manager.dat renderer.php syntax.php</span> <span class="cli_prompt">user@host:~/somedir $</span> </pre>
The full syntax:
<cli prompt='prompt ' comment='comment'> transcript </cli>
The opening <cli … > must all appear on one line. The transcript contents can appear over as many lines as are needed.
<cli> user@host:~/somedir $ ls # List current directory conf lang README screen.gif ui info.txt manager.dat renderer.php syntax.php user@host:~/somedir $ </cli>
<cli prompt="$"> $ rpm -ivh darcs-1.0.9-3.fc6.i386.rpm Preparing... ########################################### [100%] 1:darcs ########################################### [100%] </cli>
user@host:~/somedir $ ls # List current directory conf lang README screen.gif ui info.txt manager.dat renderer.php syntax.php user@host:~/somedir $
$ rpm -ivh darcs-1.0.9-3.fc6.i386.rpm Preparing... ########################################### [100%] 1:darcs ########################################### [100%]