Create a gist now

Instantly share code, notes, and snippets.

Embed
$ wget http://www-eu.apache.org/dist/maven/maven-3/3.3.9/binaries/apache-maven-3.3.9-bin.tar.gz
...
2017-08-16 23:45:35 (2.26 MB/s) - ‘apache-maven-3.3.9-bin.tar.gz’ saved [8491533/8491533]
$ tar -zxvf apache-maven-3.3.9-bin.tar.gz
...
$ sudo mv apache-maven-3.3.9 /opt/maven
$ printf 'export M2_HOME=/opt/maven\nexport PATH=${M2_HOME}/bin:${PATH}\n' | sudo tee -a /etc/profile.d/mavenenv.sh
$ source /etc/profile.d/mavenenv.sh
$ mvn --version
Apache Maven 3.3.9 (bb52d8502b132ec0a5a3f4c09453c07478323dc5; 2015-11-10T16:41:47+00:00)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment