1.下载
http://maven.apache.org/download.cgi
2.tar
tar zxvf apache-maven-3.5.0-bin.tar.gz
3.环境变量
/etc/profile
export M2_HOME=/opt/apache-maven-3.5.0 PATH=$M2_HOME/bin:$PATH
source /etc/profile
4.验证
echo $M2_HOMEecho $PATHmvn -v
时间: 2024-11-08 12:44:23