Annotation of wikisrc/templates/programlisting.mdwn, revision 1.5
1.5 ! jym 1: <pre class="programlisting"><TMPL_VAR text></pre>
1.1 jym 2: <TMPL_UNLESS NAME="text">
3:
4: ## Description
5:
6: Use this template to display a program listing, or a succession of commands (together with their output).
7:
8: Remember that shell commands may be prefixed by:
1.5 ! jym 9: * *$* when the command should be run as a normal user
! 10: * *#* when the command should be run as root
1.1 jym 11:
12: * *text* - text to display as program listing.
13:
14: ## Examples
15:
16: [[!template id=programlisting text="""
17: $ uname
18: NetBSD
19: $ cd /bin
20: $ ls
21: [ cpio domainname kill mt rcmd sleep
22: cat csh echo ksh mv rcp stty
23: chio date ed ln pax rm sync
24: chmod dd expr ls ps rmdir tar
25: cp df hostname mkdir pwd sh test
26: """]]
27:
28: is obtained with:
29:
30: \[[!template id=programlisting text="""
31: $ uname
32: NetBSD
33: $ cd /bin
34: $ ls
35: [ cpio domainname kill mt rcmd sleep
36: cat csh echo ksh mv rcp stty
37: chio date ed ln pax rm sync
38: chmod dd expr ls ps rmdir tar
39: cp df hostname mkdir pwd sh test
40: """]]
41:
42: </TMPL_UNLESS>
CVSweb for NetBSD wikisrc <wikimaster@NetBSD.org> software: FreeBSD-CVSweb