Upgrading Maven on Mac

nupac picture nupac · Nov 18, 2013 · Viewed 39.1k times · Source

Tried to upgrade maven. Followed this tutorial. Now I am getting thisenter image description here

How does a file exist and not exist?

Answer

Dark Star1 picture Dark Star1 · Aug 31, 2014

To upgrade to the latest version (if you have one already installed but need to update the version) do the following:

1. brew update
2. brew unlink maven
3. brew install maven

if you then execute the mvn --version command you should see that your version of maven has been upgraded.

EDIT:
If you have an issue with the update (command 1) that goes along the lines of
error: The following untracked working tree files would be overwritten by merge: Library/Formula/...
try this answer from another issue