Search code examples
javaspringeclipsemavenm2eclipse

m2eclipse maven build parameters


I am developing a spring mvc app using eclipse kepler with the m2eclipse plugin. How do I create a war file from within eclipse using the m2e plugin?

Do I use run as... maven build...? If so, how do I configure it? I right clicked on the root folder for the app in the eclipse workspace and chose run as... maven build..., which resulted in the following dialog box:

But I do not know what parameters to enter into the dialog box. Can anyone guide me through how to create the war file?


Solution

  • Put Goals as clean compile package

    There are three built-in build lifecycles: default, clean and site. The default lifecycle handles your project deployment, the clean lifecycle handles project cleaning, while the site lifecycle handles the creation of your project's site documentation.

    Each of these build lifecycles is defined by a different list of build phases, wherein a build phase represents a stage in the lifecycle.

    Read more about Build Lifecycle Basics


    Here is the complete description with snapshots Using the M2Eclipse Maven Plugin in Eclipse

    Please have a look at Tutorial - Maven Eclispe IDE Integration