Eclipse Integration

Before getting started, lets get Eclipse setup. Lets create a Eclipse project for the jetexpress project. Maven-2 can create Eclipse project and classpath files from your Maven-2 project POM, automatically bringing in all dependencies:

	 
# Linux	 
cd /JetspeedTraining/workspace/jetexpress
mvn eclipse:eclipse
cp portal/.classpath .
cp portal/.project .
# Windows
cd \JetspeedTraining\workspace\jetexpress
mvn eclipse:eclipse
copy portal\.classpath .
copy portal\.project .
     
     

Lets do the same for the express-demo portlet application. You may prefer to actually create a new Eclipse project to represent the portlet app subproject. We recommend this, since Eclipse doesn't work very well multi-Maven projects. Best to break them out into one Maven project == one Eclipse project:

	 
# Linux	 
cd /JetspeedTraining/workspace/jetexpress/applications/express-demo
mvn eclipse:eclipse
# Windows
cd \JetspeedTraining\workspace\jetexpress\applications\express-demo
mvn eclipse:eclipse
     
     

Now lets import these new projects. From the eclipse menu, select File->Import:

Repeat for both the applications/express-demo project.

Next, lets setup a classpath variable to point at the Maven Repo, effectively resolving the jars for Eclipse. In Eclipse, go to Window->Preferences->Java->Build Path->Classpath Variables->New...:

If you would like to work with the Jetspeed source from the SVN Trunk, you will need to install the Subversion Plugin for Eclipse. After doing so, simply check out the project using the Subversion plugin:

We are now ready to start developing with Eclipse.

Previous Next