ModPro Projects
This page explains how to create ModPro Projects.
ModPro project files are XML files that contain <mpc> elements that define command line parameters.
So it's virtually the same as if you called the compiler a number of times from the command line.
However, since it all runs in one transaction it executes much faster than using a batch file.
The root element of a project file is <project> and can contain any number of <mpc> elements.
The attributes of the <mpc> elements are equivalent to the command line parameters of the same name.
See the Compiler page for detailed information of each parameter.
|
<file>
<mpc>
<project>
|
<file>
Defines the files to compile. This element is a child of the <mpc> element.
Attributes:
- path: The path to the xml file to compile. May include wildcards (ex. path="src/*.xml")
Example:
<file path="src/pages/*.xml"/>
|
<mpc>
Defines a call to start the compiler. It can contain any number of <file> elements.
Attributes:
- out: Name of output file or pattern for one or more output files (ex. out="*.html")
- xsl: Names of xsl files used to transform the xml, seperated by semicolons (ex. xsl="mpml.xsl;nav.xsl")
- verbose: Show more compiler output.
- quiet: Show no compiler output except errors.
- rebuild: Force rebuild of all files.
- pre: reprocess only and place xml files in output directory specified by the out attribute.
Example:
<mpc out="*.html" xsl="mpml.xsl;nav.xsl" verbose="yes" rebuild="yes">
|
<project>
The root element of a project file. It can contain any number of <mpc> elements.
Attributes:
- name: Name of the project (optional)
Example:
<project name="ModPro">
<mpc out="../html/*.html">
<file path="pages/*.xml"/>
</mpc>
<mpc out="../html/modpro/*.html">
<file path="pages/modpro/*.xml"/>
</mpc>
</project>
|