Home
Categories
WIKI
Topic
User
LANGUAGE:
中文
English
etc/profile文件配置maven环境变量
Experiences and Insight
1989
views ·
1
replies ·
To
floor
Go
spq
deepin
2018-04-10 06:09
Author
我自己在maven官网上下载了3.5.3版本,归档在/home/用户下/dev/apache-maven-3.5.3文件下
然后,我切换了root账户得到权限,更改了profile文件
export
M2_HOME=
$HOME
/dev/
apache-maven-3.5.3
export
MAVEN_OPTS=
"-Xms128m -Xmx1024m"
export
PATH=
$M2_HOME
/bin:
$PATH
写入profile文件保存退出,
执行了source /etc/profile
尝试测试mvn -v命令时,确提示了无效命令
百科了网上质料,说是重新启动电脑,但是,我的电脑重启之后提示,profile文件下新增的maven环境三行,错误。
Reply
Like 0
Favorite
View the author
All Replies
spq
deepin
2018-04-10 06:14
#1
自己犯傻了(maven源代码,安装在home/用户下,使用了root用户去执行mvn -v命令),成功配置了。
Reply
Like 0
View the author
Please
sign
in first
Featured Collection
Change
Nuntia - Modern IMAP/SMTP mail client for Deepin (Beta tester wanted!)
[Tutorial] deepin25 WSL Offline Installation Guide
UOS AI 2.8 Released! Three New Intelligent Agents & Major Evolution
Solid Q&A | deepin 25 Common Questions – The Immutable System Edition
New Thread
Popular Ranking
Change
Taskbar no longer shows popups
Four agent skills for laptop power, sleep, and honest bug reports
Popular Events
More
然后,我切换了root账户得到权限,更改了profile文件
export M2_HOME=$HOME/dev/apache-maven-3.5.3
export MAVEN_OPTS="-Xms128m -Xmx1024m"export PATH=$M2_HOME/bin:$PATH写入profile文件保存退出,
执行了source /etc/profile
尝试测试mvn -v命令时,确提示了无效命令
百科了网上质料,说是重新启动电脑,但是,我的电脑重启之后提示,profile文件下新增的maven环境三行,错误。