抱歉,您的浏览器无法访问本站
本页面需要浏览器支持(启用)JavaScript
了解详情 >

1.mkdir -p /data/maven

2.wget http://mirrors.shu.edu.cn/apache/maven/maven-3/3.5.3/binaries/apache-maven-3.5.3-bin.tar.gz

3.tar -zxvf apache-maven-3.5.3-bin.tar.gz

4.修改conf setting

1
2
3
4
5
6
7
<mirror>  
<id>nexus-aliyun</id>
<mirrorOf>central</mirrorOf>
<name>Nexus aliyun</name>
<url>http://maven.aliyun.com/nexus/content/groups/public</url>
</mirror>
<localRepository>/data/java/repo</localRepository>

5.vi /etc/profile

1
2
3
export MAVEN_HOME=/usr/local/maven/apache-maven-3.5.2

PATH=$JAVA_HOME/bin:$MAVEN_HOME/bin:$PATH

保存
source /etc/profile

评论