Sometimes you need to update the environment variables permanently. I have found setting JAVA_HOME and M2_HOME as an important and recurring requirement while working in Adobe, Symantec and even at Expedia Group. I am listing the steps here. Its simple :)
Steps:
- Open Bash profile: vi ~/.bash_profile
- Append: export M2_HOME=/Users/mfaiz/Projects/apache-maven-3.6.0/bin
- export PATH=$PATH:$M2_HOME
- export JAVA_HOME=/Users/mfaiz/my-jdk/Mac
- On terminal run: source ~/.bash_profile
- You can verify the install using: mvn - - version (This will show you version eg 3.6.0 in my case)
No comments:
Post a Comment