- Added a Tcl template processing facility to SICS
This commit is contained in:
38
tcl/tjxphelp
Normal file
38
tcl/tjxphelp
Normal file
@ -0,0 +1,38 @@
|
||||
|
||||
|
||||
Tcl Template Processing System.
|
||||
|
||||
This is a test file and help text for my Tcl template processing
|
||||
system. It was inspired by JSP and JXP. But is in my favourite
|
||||
scripting language Tcl. Basically it allows to mix Tcl scripts with
|
||||
text. The text can contain special marks which are then executed as
|
||||
Tcl scripts in a variety of ways. Three tags are supported:
|
||||
|
||||
<%! set var waschmaschine %>
|
||||
|
||||
This tag executes the Tcl script but prints nothing, except may
|
||||
be error messages. Please note that this can be used to source
|
||||
more Tcl files which contains procedures you need for doing your
|
||||
work.
|
||||
|
||||
<%=var %> prints the value of the Tcl variable var. When processed,
|
||||
this should print waschmaschine.
|
||||
|
||||
<% set a [list 1 2 3]
|
||||
join $a
|
||||
%>
|
||||
executes the Tcl code within and prints the result. This should be
|
||||
1 2 3.
|
||||
|
||||
All Tcl code is executed at global level. There is nothing more to
|
||||
this. All this was done in 75 lines of Tcl, including comments! You
|
||||
should be able to process this file through tjxp to see what you get.
|
||||
Txjp is brough to you by:
|
||||
|
||||
Mark Koennecke, Mark.Koennecke@psi.ch
|
||||
|
||||
txjp is copyrighted under the GNU Public Licence 2.0, which you can
|
||||
find elsewhere.
|
||||
|
||||
Enjoy!
|
||||
|
Reference in New Issue
Block a user