How to Install Apache Maven 3 on Mac OS X Easy-Visual Guide

May 11, 2013 | By Regaz | Filed in: Uncategorized.

The Guide shows you How to Install and Getting-Started with the Latest Apache Maven 3 Java Project Management & Build Tool for macOS Desktop.

The Contents and Details are Essentials and Give Focus only to Instructions and Commands.

Apple on Cloud
  1. Download Latest Apache Maven 3 Binaries:

    Maven 3 bin.tar.gz
  2. Double-Click on Archive and Extract Maven3 Binaries

  3. Open a Terminal Window
    (Press “Enter” to Execute Commands)

  4. Relocate Maven3 Binaries

    sudo su

    If Got “User is Not in Sudoers file” then see: How to Enable sudo

    mv /apache-maven-3* /opt
  5. Check if Java is Installed

    java -version
  6. Setup Maven3 Path and Environment Variables

    su <username>
    nano ~/.profile

    Insert Something Like:

    export M3_HOME=/opt/apache-maven-3.0.4
    export M3=$M3_HOME/bin
    export PATH=$M3:$PATH
    export JAVA_HOME=/System/Library/Java/JavaVirtualMachines/<1.X.Y.jdk>/Contents/Home
    export PATH=$JAVA_HOME/bin:$PATH

    Load New .bashrc SetUp.

    source ~/.profile
  7. Test Maven3 Installation

    mvn -v

    If you Get the Maven Version the Apache Maven has been Successfully Installed on Your Mac System :)

Tags: , , , , , , , , ,