• Install maven3 in Ubuntu 11.10

    by  • January 17, 2012 • Tech, Tips and Trick • 0 Comments

    Maven3 packages deb packages are already available in few 3rd party PPAs [1], though in case you want to go with the latest version of maven3 here are the steps you can apply to install maven3:

    1) Remove existing maven2 :
    sudo apt-get purge maven*
    2) Install Maven3 :
    $ sudo su -
    $ mkdir /opt/MAVEN
    $ (cd /opt/MAVEN && wget http://apache.unixteacher.org//maven/binaries/apache-maven-3.0.3-bin.tar.gz -O- | tar -xzv && ln -sf apache-maven-3.0.3 current)
    $ cat >/etc/profile.d/maven.sh <<EOF
    export M2_HOME="/opt/MAVEN/current"
    export MAVEN_HOME="/opt/MAVEN/current"
    export M2="/opt/MAVEN/current/bin"
    export PATH=$M2:$PATH
    $ wget http://goo.gl/8Sugr -O /etc/bash_completion.d/maven3

    [1] https://launchpad.net/~natecarlson/+archive/maven3


    Software surveyor

    Leave a Reply

    Your email address will not be published. Required fields are marked *