3
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Strict//EN">
6
<title>Template::Tools::tpage</title>
7
<link rel="stylesheet" type="text/css" href="../css/blue.css" title="Clear Blue">
8
<link rel="alternate stylesheet" type="text/css" href="../css/orange.css" title="Clear Orange">
9
<link rel="alternate stylesheet" type="text/css" href="../css/green.css" title="Clear Green">
10
<link rel="alternate stylesheet" type="text/css" href="../css/purple.css" title="Clear Purple">
11
<link rel="alternate stylesheet" type="text/css" href="../css/grey.css" title="Clear Grey">
13
<link rel="stylesheet" type="text/css" href="../css/ie6.css" />
15
<link rel="stylesheet" type="text/css" href="/css/print.css" media="print">
16
<script type="text/javascript" src="../js/tt2.js"></script>
17
<meta http-equiv="Content-Type" content="text/html;charset=utf-8">
18
<meta name="author" content="Andy Wardley">
23
<a href="../index.html" id="logo" alt="" title="Click for the Home Page"><span class="alt">TT2 Home Page</span></a>
25
<li><a href="../tools/index.html">Tools</a></li>
26
<li class="last"><a href="../tools/tpage.html">tpage</a></li>
28
<div class="controls">
29
<a href="#" class="menu show" onclick="widescreen_off(); return false" title="Show Menu">
30
<span class="about">Click to view the menu. It's very nice.</span>
32
<a href="#" class="menu hide" onclick="widescreen_on(); return false" title="Hide Menu">
33
<span class="about">Click to hide the menu and go all widescreen!</span>
37
<span class="go back">Back<span class="about">No, you can't go back. You're silly to even think that you could.</span></span>
38
<a href="../tools/index.html" title="Template::Tools" class="go up">Up<span class="about"><h4>Template::Tools</h4>Command Line Tools for the Template Toolkit</span></a>
39
<a href="../tools/ttree.html" title="Template::Tools::ttree" class="go next">Next<span class="about"><h4>Template::Tools::ttree</h4>Process entire directory trees of templates</span></a>
42
<h1 class="headline">Template::Tools::tpage</h1>
43
<h2 class="subhead">Process templates from command line</h1>
48
<a href="../index.html" id="logo"></a>
51
<li class="l0 first"><a href="../manual/index.html">Manual</a></li>
52
<li class="l0"><a href="../modules/index.html">Modules</a></li>
53
<li class="l0"><a href="../tools/index.html" class="warm">Tools</a></li>
54
<li class="l1"><a href="../tools/tpage.html" class="warm">tpage</a></li>
55
<li class="l1"><a href="../tools/ttree.html">ttree</a></li>
56
<li class="l0 last"><a href="../tutorial/index.html">Tutorial</a></li>
58
<div class="foot"></div>
64
<h1 id="contents" onclick="switch_section(this)" title="Click title to show/hide section content.">Contents</h1>
65
<a href="#body" class="top" title="Back up to the top of the page" >Top</a>
69
<li class=""><a href="#USAGE">USAGE</a></li>
70
<li class=""><a href="#DESCRIPTION">DESCRIPTION</a></li>
71
<li class=""><a href="#AUTHOR">AUTHOR</a></li>
72
<li class=""><a href="#COPYRIGHT">COPYRIGHT</a></li>
73
<li class=""><a href="#SEE_ALSO">SEE ALSO</a></li>
82
<h1 id="USAGE" onclick="switch_section(this)" title="Click title to show/hide section content.">USAGE</h1>
83
<a href="#body" class="top" title="Back up to the top of the page" >Top</a>
86
<pre>tpage [ --define var=value ] file(s)</pre>
91
<h1 id="DESCRIPTION" onclick="switch_section(this)" title="Click title to show/hide section content.">DESCRIPTION</h1>
92
<a href="#body" class="top" title="Back up to the top of the page" >Top</a>
96
The <b>tpage</b> script is a simple wrapper around the Template Toolkit
97
processor. Files specified by name on the command line are processed in
98
turn by the template processor and the resulting output is sent to STDOUT
99
and can be redirected accordingly. e.g.
101
<pre>tpage myfile > myfile.out
102
tpage header myfile footer > myfile.html</pre>
104
If no file names are specified on the command line then <b>tpage</b> will
105
read STDIN for input.
108
The <code>--define</code> option can be used to set the values of
109
template variables. e.g.
111
<pre>tpage --define author="Andy Wardley" skeleton.pm > MyModule.pm</pre>
113
See <a href="../modules/Template.html">Template</a> for general
114
information about the Perl Template Toolkit and the template language and
119
<div class="section">
121
<h1 id="AUTHOR" onclick="switch_section(this)" title="Click title to show/hide section content.">AUTHOR</h1>
122
<a href="#body" class="top" title="Back up to the top of the page" >Top</a>
126
Andy Wardley <abw@wardley.org>
129
<a href="http://wardley.org/">http://wardley.org/</a>
133
<div class="section">
135
<h1 id="COPYRIGHT" onclick="switch_section(this)" title="Click title to show/hide section content.">COPYRIGHT</h1>
136
<a href="#body" class="top" title="Back up to the top of the page" >Top</a>
140
Copyright (C) 1996-2007 Andy Wardley. All Rights Reserved.
143
This module is free software; you can redistribute it and/or modify it
144
under the same terms as Perl itself.
148
<div class="section">
150
<h1 id="SEE_ALSO" onclick="switch_section(this)" title="Click title to show/hide section content.">SEE ALSO</h1>
151
<a href="#body" class="top" title="Back up to the top of the page" >Top</a>
155
<a href="#section_ttree">Template::Tools::ttree</a>
162
<div class="pageinfo">
163
/tools/tpage.html last modified 10:55:13 31-May-2007
168
<a href="http://opensource.org/" class="osi"></a>
169
<div class="controls">
171
<span class="go back">Back<span class="about"></span></span>
172
<a href="../tools/index.html" title="Template::Tools" class="go up">Up<span class="about"><h4>Template::Tools</h4></span></a>
173
<a href="../tools/ttree.html" title="Template::Tools::ttree" class="go next">Next<span class="about"><h4>Template::Tools::ttree</h4></span></a>
176
<div class="copyright">
177
Copyright © 1996-2007 <a href="http://wardley.org/">Andy Wardley</a>. All Rights Reserved.
179
<div class="licence">
180
The <a href="http://template-toolkit.org/">Template Toolkit</a> is <a href="http://opensource.org/">Open Source</a> software.
181
You can redistribute and/or modify it under the terms of the <a href="http://www.opensource.org/licenses/gpl-license.php">GNU Public Licence</a>
182
or the <a href="http://www.opensource.org/licenses/artistic-license.php">Perl Artistic Licence</a>.
187
<li class="first"><a href="#" class="blue" onclick="set_style('Clear Blue')"></a></li>
188
<li><a href="#" class="orange" onclick="set_style('Clear Orange')"></a></li>
189
<li><a href="#" class="green" onclick="set_style('Clear Green')"></a></li>
190
<li><a href="#" class="purple" onclick="set_style('Clear Purple')"></a></li>
191
<li><a href="#" class="grey" onclick="set_style('Clear Grey')"></a></li>