Maven下载与配置
1、官网下载对应版本,推荐下载免安装版
[下载地址](https://archive.apache.org/dist/maven/maven-3/3.6.1/binaries/)
![](https://gitee.com/hg14150/blogiamges/raw/master/img/image-20210404133834598.png#alt=image-20210404133834598)
2、配置setting.cof
2.1、配置本地仓库
<!-- localRepository
| The path to the local repository maven will use to store artifacts.
|
| Default: ${user.home}/.m2/repository
<localRepository>/path/to/local/repo</localRepository>
-->
<!--路径为maven解压地址-->
<localRepository>D:\Major_Application\Java\maven3.6.1\repository</localRepository>
2.2、配置阿里仓库
<mirror>
<id>alimaven</id>
<name>aliyun maven</name>
<url>http://maven.aliyun.com/nexus/content/groups/public/ </url>
<mirrorOf>central</mirrorOf>
</mirror>
3、配置环境变量
win
+E
打开文件管理—>右击此电脑—>属性—>高级系统设置—>环境变量—>系统环境变量path
,新建添加如下信息
#maven解压路径\bin
D:\Major_Application\Java\maven3.6.1\bin
4、测试
win
+R
打开命令提示符输入cmd
,输入以下内容出现如图内容,说明大功告成啦啦啦
mvn -v
5、IDEA托管maven
File -> Setting -> 搜索Maven
配置完成apply/ok就可以啦啦啦