1.安装maven 插件
从eclipse 3.7(indigo)之后,m2e 插件已host到eclipse.org 站点下:
Since Eclipse 3.7 (Indigo), m2e is now hosted at eclipse.org. To install it, you just need to use the default Eclipse update site:
- http://download.eclipse.org/releases/kepler
- http://download.eclipse.org/releases/juno
- http://download.eclipse.org/releases/indigo
- http://download.eclipse.org/releases/helios/
2.配置环境变量
从http://maven.apache.org/download.cgi 下载maven 解压到C:\apache-maven-3.1.1
- 配置环境变量M2_HOME,值为C:\apache-maven-3.1.1
- 配置环境变量M2,值为%M2_HOME%\bin
- 更新PATH环境变量的值,在后面添加;%M2%
- 配置JAVA_HOME环境变量,值为C:\Program Files\Java\jdk1.6.0_03,并将%JAVA_HOME%\bin添加到PATH环境变量的值后面。
- 最后在命令行中运行mvn –version 检测maven是否安装成功。