<?xml version="1.0"?>

<document>

  <properties>
    <title>Melati Maven Archetype - Java SQL Website Development Engine</title>
    <author email="timp@paneris.org">Tim Pizey</author>
    <keywords>
      Persistence, Java, SQL, Database, Templates, Object Relational Mapping,
      Objects, Object Oriented
    </keywords>
  </properties>

  <body>


<!--
<p align="center">
 <font size="-1"><i>
This page last updated: $Date: 2010/03/10 16:43:41 $ $Author: timp $
 </i></font>
</p>
-->
  
<!-- menu -->

<section name=" Melati Maven Archetype">
<subsection name=" Generate a prototypical Melati project ">
<pre>
<input type='text' size='180' 
value = 'mvn archetype:create -DarchetypeGroupId=org.melati -DarchetypeArtifactId=melati-archetype -DarchetypeVersion=0.7.8-RC3-SNAPSHOT -DgroupId=com.ical -Dversion=0.7.8-RC3-SNAPSHOT -DartifactId=art' />
</pre>
<p>
This will create a project with id <tt>art</tt> and a group <tt>com.ical</tt> in a directory below the current working directory called <tt>art</tt>.
</p>
<p>
Note that we are hacking the version to be the melati version. Also the pom will contain a one-off ant-run task which can be deleted.
</p>
<pre>
cd art
mvn install
mvn -DdownloadSources=true -DdownloadJavadoc=true eclipse:eclipse
</pre>
</subsection>
<subsection name=" Iterative modelling ">
<p>
You can then run:
</p>
<pre>
mvn jetty:run
</pre>
<p>
This will create an empty database and allow you to edit it at <a href="http://localhost:8080/">http://localhost:8080/</a>.
You should login using the username <tt>_administrator_</tt> and password <tt>FIXME</tt> then add table definitions and 
column definitions.
</p>
<p>
When you have finished, for now, stop Jetty with <tt>Ctrl-C</tt>.
</p>
<p>
New java files will be generated the next time you run <tt>mvn test</tt>.
</p>
</subsection>
</section>
</body>
</document>


