Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Stage two (if you're running JDK 5):
{{mvn -Pjdk1.5 install }}

You may need to run with -Dmaven.test.skip=true if you have failing unit tests (this obviously
shouldn't be the case for a release build).

...

Commandline

Description

mvn clean

cleans up build artifacts

mvn compile

compiles the projects

mvn package

creates the jar files in the target/ subdirectories

mvn install

installs the jar files in your local repository

You can just run the install target, as Maven will build the previous stages automatically.

Building Wicket 2.x

Wicket 2.x development is done in the trunk of our subversion repository. Wicket 2.x will
also only run on JDK 1.5 or newer. Therefore building Wicket 2.x is easier than building Wicket 1.x.

Getting the latest and greatest for Wicket 2.x development is as easy as:

svn co https://svn.apache.org/repos/asf/incubator/wicket/trunkImage Added

then change the directory to the wicket-parent subdirectory and run:

mvn install

As this is our main development you might/will encounter failing unit tests. These can be skipped using:

mvn -Dmaven.test.skip=true install

Of course, all limits are off then and your mileage may vary if you use such a built jar.

Using your own built artifacts

Now you have built your own fresh Wicket jar you must be anxious to use it. This is now as simple as adding
a snapshot dependency on the specific Wicket version. So in your pom.xml you can use:

Code Block
xml
xml

<dependency>
    <groupId>org.apache.wicket</groupId>
    <artifactId>wicket</artifactId>
    <version>1.3-incubating-SNAPSHOT</version>
    <scope>compile</scope>
</dependency>

And adding this to your Eclipse or NetBeans project classpath is then as simple as:

  • mvn eclipse:eclipse or
  • mvn netbeans:netbeans

Maven will then add all the necessary JAR files to the project's classpath.

One thing you need to make sure is that you have set the M2_REPO classpath variable in
Eclipse (or a similar construct in Netbeans), and point it to your local repository, typically found in
C:\Documents and Settings\username\.m2\repo or (for unix buffs) ~/.m2/repo------------------------------------------------------------------------