Configure maven,mvn: command not found? under mac


JAVA_HOME=/Library/Java/JavaVirtualMachines/jdk1.8.0_161.jdk/Contents/Home 
PATH=$JAVA_HOME/bin:$PATH:.
CLASSPATH=$JAVA_HOME/lib/tools.jar:$JAVA_HOME/lib/dt.jar:.
export M2_HOME="/Applications/apache-maven-3.5.3" 
export PATH="$M2_HOME/bin:$PATH" 
export JAVA_HOME
export PATH
export CLASSPATH
Mar.14,2021

JAVA_HOME=/Library/Java/JavaVirtualMachines/jdk1.8.0_161.jdk/Contents/Home
M2_HOME=/Applications/apache-maven-3.5.3
PATH=$JAVA_HOME/bin:$M2_HOME/bin:$PATH:.
CLASSPATH=$JAVA_HOME/lib/tools.jar:$JAVA_HOME/lib/dt.jar:.
export M2_HOME
export JAVA_HOME
export PATH
export CLASSPATH
Why not write this way, it has not been matched on MAC, it is just a guess.


the first method has been given on the first floor. The second method, brew install maven, and the third method, sdk install maven.


mac is better to use the package manager. Like homebrew. Just one command for anything

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1e501d9-43db2.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1e501d9-43db2.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?