Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

install maven 3.6.0 on Mac

Tags:

macos

maven

I am trying to install a specific version of man.brew install [email protected] is not working due to lack of 3.6 version (there is 3.5, 3.2, 3.3). installation with this guide https://maven.apache.org/install.html also not. zsh: man not found Any ideas?

like image 764
djasyfuj Avatar asked Nov 03 '25 17:11

djasyfuj


1 Answers

You can use Maven Version Manager to manage multiple versions of maven. You can have a folder-specific maven version.

Steps

  1. If you already installed the maven brew formula uninstall it brew remove --force maven
  2. Install mvnvm. brew install mvnvm
  3. To set the global maven version add an environment variable named DEFAULT_MVN_VERSION with the maven version you want as default as the value.
  4. To set a Maven version for a specific folder create a file named mvnvm.properties in that folder and have the following content.
    mvn_version=<maven version for the folder>
    
like image 71
Karthikeyan Vaithilingam Avatar answered Nov 05 '25 15:11

Karthikeyan Vaithilingam



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!