Getting started with WO Development using Maven
This tutorial focuses on getting started with Maven in Eclipse/Development. Maven and the Maven integration plugin are bundled with Eclipse so you don't need to install anything additional.
We don't cover Maven building on the CLI nor do we discuss concepts or how any of this actually works. This just gets the darned thing up and running, we can talk concepts and understanding later. So:
Let's set it up
1. Let Maven know WO/Wonder exists
Maven needs to know where to fetch the WO/Wonder frameworks and jars. If you're starting fresh, that means copying
settings.xml (seen below in this gist) into
~/.m2/settings.xml. Now Maven knows where WOCommunity keeps it's stuff.
2. Let Eclipse know how to create new WO/Wonder projects
Open Eclipse. Go to Preferences and select
Maven -> Archetypes. Click
Add Remote Catalog and insert the url below in the
Catalog file field. Enter anything you want for
Description, such as "WOCommunity".
Creating a project
- Go to
File -> New -> Otherand select
- From the
Catalogpopup, select the archetype catalog you added previously
erxapplication-archetype(3.0 is current at the time of writing)
- In the next step, if you don't know what
Artifact Idmeans, just write
testinto both fields. These can be easily altered later and
testwill do just fine.
Packagecan be left as is.
1.8(or whatever your preferred java version is) and
7.2(latest stable release of Wonder when this is written).
Finishand we're done.
Congratulations! You have a Maven project! You can now run your application like any old WO application.