Eclipse integrated maven (manually installing Maven and manually integrating into Eclipse)

Source: Internet
Author: User

1. Operating Environment

Operating system: WIN8 64-bit

Ide:helios Eclipse 1.8

jdk:1.6

2. Resource Preparation

2.1 Maven installation package: Apache-maven-3.2.5-bin.zip (for JDK 1.6)

Reference: HTTP://MIRRORS.CNNIC.CN/APACHE//MAVEN/MAVEN-3/3.2.5/

2.2 Maven Integration pack: Eclipse-maven3-plugin.zip

Reference: http://www.downcc.com/soft/17592.html

3. MAVEN Installation Work

3.1 Download the Maven install package after the decompression (recommended file name modification, good remember. such as maven3.2.5), stored in the hard drive directory you want to put

Take my example: D:\EditWorld\maven3.2.5

3.2 Configuring environment variables (not added)

Location: Right-click My Computer >> Select Properties >> Select "Environment variables" under "Advanced system Settings" in upper left corner >> Advanced tab;

The variables to be set are as follows:

A) system variable: maven_home = D:\EditWorld\maven3.2.5

B) User variable: path =%maven_home%\bin;

Reminder: When you configure a user variable, because the path variable already exists, and when appended, note the previous%maven_home%\bin

If there is a semicolon (;), no complement is appended, otherwise the configuration is invalid.

3.3 Verifying that the installation is successful

Press the shortcut key: Win +r, input cmd, in console input: mvn-version, you can see the MAVEN version information,

Indicates that the installation was successful.

    

3.4 Warehouse Configuration

A) Warehouse Path settings

Locate the Settings.xml configuration file locally under the MAVEN installation directory conf, and mine is in

D:\EditWorld\maven3.2.5\conf\settings.xml, locate the Localrepository label for the configuration path and install the MAVEN

Path, such as:

    

B) resources such as the jar packages required to download the warehouse

Press the shortcut key: Win +r, enter cmd, input in console: mvn help:system, will download maven required jar Package resources.

4. Eclipse Integration

4.1 Installation within eclipse (omitted)

Because of the version of Eclipse, some people (the later the Eclipse version, the larger the number of people) failed to install successfully, always prompt similar to the following error:

Cannot complete the install because one or more required items could not be found.

Most of the information on the web suggested reducing the eclipse version, which is too cumbersome and inconvenient.

4.2 Custom integration into Eclipse (recommended)

Since the 4.1 approach is not necessarily feasible, we can take the manual configuration for integration and use eclipse-maven3-plugin.7z for integration.

4.2.1 through the link way

A) Create two folders in the root directory of your eclipse installation: links and Mavenplugins (customizable), integrate the JAR package

(eclipse-maven3-plugin.7z) The extracted features and plugins folders are placed under the Mavenplugins folder.

B) Create a Maven.link (customizable) file in the Links directory and configure the absolute path to the Path=pathmavenplugins

namely Path=d:\\editworld\\eclipse\\mavenplugins

C) Restart Eclipse, after launch you open window>>preferences, if the MAVEN option appears, the integration configuration is successful!

4.2.2 Simpler Direct Way

A) Import the unpacked subfolder features and plugins jar package files into the features and plugins folders in the Eclipse installation directory respectively;

B) After you restart Eclipse, see the MAVEN option in Window>>preferences. MAVEN integration is successful!

4.3 Checking the configuration of Maven in eclipse

Open Window>>preferences>>maven>>user Setting and check if the path under User Setting (open file) is the default

The warehouse path, if it is, change to our own settings.xml path. As my local Maven installation directory is: D:\EditWorld\maven3.2.5\,

The D:\EditWorld\maven3.2.5\conf\settings.xml is configured. (as per personal situation)

  

This completes the configuration. Hope to help those in need.

The following will update the MAVEN project management combat chapter.

Eclipse integration Maven (manually installing Maven and manually integrating into Eclipse)

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.