eclipse/idea 配置maven

①:下载maven压缩包,解压即可;

②:配置环境变量,MAVEN_HOME → E:\maven\apache-maven    path  %MAVEN_HOME%\bin;

③:设置maven本地仓库;

④:eclipse添加maven设置:window→preferences→maven

⑤:idea设置maven:file→Settings→搜索maven  或者  点击 Build,Execution,Deployment→Build Tools→Maven

 

 

检测是否配置好的命令  cmd→mvn -version

settings.xml 拷贝到 c:/用户/abcd/.m2 里面。

本地仓库地址

<!-- localRepository
| The path to the local repository maven will use to store artifacts.
|
| Default: ${user.home}/.m2/repository
<localRepository>/path/to/local/repo</localRepository>
-->

<localRepository>盘符:\maven\repository</localRepository>

阿里的镜像:

<mirrors>

  <mirror>
  <id>alimaven</id>
  <name>aliyun maven</name>
  <url>http://maven.aliyun.com/nexus/content/groups/public/</url>
  <mirrorOf>central</mirrorOf>
  </mirror>
</mirrors>

posted @ 2018-09-14 16:30  Cxvvy  阅读(321)  评论(0编辑  收藏  举报