How-to: Set up Eclipse Subversive to work with Maven Projects

Last week, I configured Eclipse to check out Maven projects properly with the Subversive SVN plugin. This plugin will allow you to directly check in/out Maven code from your SVN into Eclipse, which will save you a lot of time.

Setting up Plugins

Here are nine steps for setting everything up properly. Note that if you simply want to install Subversive and do not care for the Maven integration, you can stop after Step 6:

  1. Open Eclipse and click Help > Eclipse Marketplace

    eclipsemarketplace

    Help > Eclipse Marketplace menu

  2. Search the Marketplace for “Subversive” and choose to Install Subversive – SVN Team Provider 1.1.2
  3. Restart Eclipse once this installation has finished.
  4. When Eclipse starts again, install the SVN connectors for Subversive. Go to Help > Install New Software and enter http://community.polarion.com/projects/subversive/download/eclipse/3.0/juno-site/ into the “Work with:” field
  5. Place a checkmark next to: Subversive SVN Connectors.  Feel free to install any other connectors you may need as well.
  6. Click Finish to install the SVN connector. This may require another restart of Eclipse.
  7. Next, install the Maven2Eclipse plugin: click Help > Eclipse Marketplace and search for Maven2Eclipse then install it, following steps 2 and 3 above for that plugin.
  8. Finally, install Subversive Maven Integration. Go to Help > Install New Software again and enter http://community.polarion.com/projects/subversive/download/integrations/update-site/ into the “Work with:” field
  9. Place a checkmark next to Subversive Integration for the M2Eclipse Project and click Finish to install it.

Checking out Maven Projects

Once you have all of this set up, you will be able to check code directly in and out of your SVN from within Eclipse, which is much more convenient than copying projects into Eclipse manually.

Click on Window > Open Perspective > Other > SVN Repository Exploring

eclipseopenperspective

Eclipse’s Open Perspective dialog.

There, you can right-click the Repositories window and add the web address for your SVN.
Checking out a project is easy – right click any SVN folder to Check Out as Maven Project and specify which pom.xml file to use.

This should save you a significant amount of time once you have configured it correctly! Happy coding!

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s