Signup/Sign In

Maven with Eclipse IDE

Maven also provides an excellent plugin which helps to integrate both eclipse and maven together. M2eclipse is the plugin used to integrate maven and eclipse. Below are some of the key benefits of this plugin:

  • Launching maven builds from the eclipse.
  • Launching maven goals as well.
  • Managing the dependencies for eclipse build path.
  • Automatic download of maven dependencies from the repository.
  • GUI based (wizards based) for creating maven projects.
  • Quick fix for the required dependencies.

Install m2eclipse Plugin

Follow the below link to easily install the m2eclipse plugin in your eclipse IDE.

http://books.sonatype.com/m2eclipse-book/reference/ch02s03.html


Creating a Maven project in Eclipse

Below is the step by step explanation on creating a maven project in eclipse.

  1. Open the eclipse. Go to File -> New -> Project and search by the keyword maven and select Maven Project

    Maven Project with Eclipse IDE

  2. Select the checkbox saying, Create a simple project and click on Next.

    Maven Project with Eclipse IDE

  3. Provide the details for groupId, artifactId, version and packaging as shown below and click on Finish.

    Maven Project with Eclipse IDE

  4. A new project name SampleMavenProject will be created as shown below:

    Maven Project with Eclipse IDE


And this ends the Maven Tutorial, hope you had a great learning experience.