1) Download the Maven,
% cd && touch .zshenv && open .zshenv
Note :
- On macOS 10.5 Catalina or later, the default shell is zsh (.zshenv).
- For macOS 10.14 Mojave and before, the default Terminal shell is bash (.bash_profile).
5) Adde below lines of code in appropriate files:
export M2_HOME="/Users/{username}/apache-maven-3.8.5"
PATH="${M2_HOME}/bin:${PATH}"
export PATH
6) Source the ~/.zshenv
to reflect the changes:
% source ~/.zshenv
7) Verify to check using mvn:
% mvn -version
Apache Maven 3.8.5 (3599d3414f046de2324203b78ddcf9b5e4388aa0)
Maven home: /Users/{username}/apache-maven-3.8.5
Java version: 11.0.13, vendor: Oracle Corporation, runtime: /Library/Java/JavaVirtualMachines/jdk-11.0.13.jdk/Contents/Home
Default locale: en_IN, platform encoding: UTF-8
OS name: "mac os x", version: "11.3", arch: "x86_64", family: "mac"
meena@MEENAs-MacBook-Pro ~ %
No comments:
Post a Comment