Tag Archives: dependency management

Setting up Maven

What is Maven?

Maven is a “build & dependency management tool“. It addresses two aspects of building software: First, it describes how software is built, and second, it describes its dependencies.

Maven Setup

Let’s see how to setup the maven.

Prerequisites

Download the maven from the below link,

http://www.gaidso.com/apache/maven/maven-3/3.1.1/binaries/apache-maven-3.1.1-bin.zip

Installation

  • Extract the apache-maven-3.1.1-bin.zip file and place the apache-maven-3.1.1 folder into C Drive or anywhere you want.

Environment Variable Setup

  • Go To control panel and search for environment then you would get System Icon. Then click on the Edit Environment variable for your account.

Environemnt Variable1

  • Now you would get the Environment variable Window,

Environemnt Variable2

  • Add the below Variables by click Add button,
Variable Name Variable Value
JAVA_HOME C:\Program Files\Java\jdk1.6.0_30
M2_HOME C:\apache-maven-3.1.1
PATH C:\ProgramFiles\Java\jdk1.6.0_30\bin; C:\apache-maven-3.1.1\bin

Environemnt Variable3

  • Now the Maven setup has been done, you could check whether the configuration is done properly or not by doing the below steps,
  • Goto Run and type cmd,

cmd

  • You would get command prompt as like below, then type mvn –version and press enter key. You could able to see the maven version details, if not probably you might be missed some configurations. So kindly verify the steps.

mvn

Happy Learning!!!