Apache Maven is a software project management and comprehension tool. Based on the concept of a project object model (POM), Maven can manage a project's build, reporting and documentation from a central piece of information.Here, I want to show how to configure maven to use as external tool in eclipse IDE so easy for you to execute maven commands from the Eclipse interface easy without needing to open a DOS prompt to use. Here is the procedure:
1. Suppose maven 2 already install some where on your PC, (mine is in D:\Work\install\Tools\maven-2.0.4)
2. From the menu bar, select Window > Preferences. Select the Run/Debug > String Substitution. Add a new variable e.g. maven_exec.
3. Set up a new external launcher from the menu bar, select Run > External Tools. Select Program
4. Create each maven task, example: in here, I create only the build classpath
- On program, create a new program and name as: build_classpath (any name as you wish)
- In location box: choose our created variable: maven_exec
- In Working Directory: choose variable: project_loc
- In Argument, give maven command, in here is: eclipse:clean eclipse:eclipse
- Click on Apply and Run if you wish now
Enjoy,
No comments:
Post a Comment
Note: Only a member of this blog may post a comment.