DML2  v1.0.1
Sections
Introduction to DML2
Getting Started
Files and Directories
Custom Tags
File Output
Creating Objects
Rendering and Scope
Object Execution
Arrays
Rendering Arrays
Constructors
Includes
Automatic Tags
dml2build
About
Release Notes
<( dml2build )>

Congratulations, you've mastered the DML2 language! Of course, you might like to know how to output your own files using dml2build now. From inside of your dml2/ directory (the one where you store your DML2 files), just run dml2build with a list of parameters. The list of parameters is a list of DML2 files you would like to process (and have them output files). You may also specify all as a parameter. This will read the current directory and parse/output all of the .dml2 files in the directory.


dml2build file1.dml2 file2.dml2 content.dml2
dml2build all


DML2 should give you some friendly output when you execute it (or maybe some errors if something's wrong). If you would like to rebuild this documentation, just go into the docs/dml2/ directory and run the following command:


dml2build html_template.dml2 text_template.dml2 man_template.dml2


You may also run the dml2build program from a directory that your source files are not in (all includes will be resolved relatively). However, if you are not in the source directory, you cannot use all to read all the .dml2 files.

You can also use the -o parameter to specify where the output files are written to. This defaults to ../ since dml2build is normally run from within the dml2 source directory. For example, the following command writes /files/html_template.dml2's output files to the /files/output directory.


dml2build /files/html_template.dml2 -o /files/output



!Note: It is significantly faster to run DML2 once with many files than to run it many times in a row with a single file each time. This is because it must parse included files only once if your run DML2 once, whereas with many executions, it must parse the same files repeatedly.

http://derajdezine.vze.com/
©2002 Jared Krinke. ((( Revolution )))