Maven is a tool used to build our applications. It is written in xml format in the file pom.xml. http://maven.apache.org/ will guide in understanding maven.
Working with maven for the first time.
1. Download Apache Maven(bin) from http://maven.apache.org/download.html.
2. Unzip into C:/Maven
3. Set Path M2_HOME pointing to the home directory and M2_Repo pointing to a repository what we created inside maven.
4. Set the path to M2\bin so that maven gets included into the path.
5. Run the commands given the http://maven.apache.org/ link. [go to the maven home directory and create repository]
6. While running for the first time maven will download all the necessary files.
7. Run the sample test program given in the my-app(this will be created when we run the create project command from the above link) directory.
8. pom.xml is the build file containing the build commands and dependencies.
9. From command prompt just go to the directory of pom.xml in the workspace and run the commands.
No comments:
Post a Comment