tags:

views:

117

answers:

3

I'm tasked with getting a development environment set up for a new program at work. The lead has chosen Eclipse as the IDE for its OSGi support and Maven as the build utility.

I've struggled through getting Maven integrated with Eclipse and I'm grudgingly declaring success and moving forward.

My question: is there any sort of guide to getting started with Maven? I've found boatloads of documentation, most all of it very, very detailed and simultaneously unhelpful. I downloaded a 300+ page book that goes into excruciating detail about POMs, but doesn't tell you how to initialize a project from existing source.

Hopefully, this question will result in a pointer to something I missed or a collection of links for those who follow me.

+1  A: 

As a basic start i would suggest to take a look at 5 Minutes Guide on the Maven site. If you have an existing project you should take a look in particular the folder structure and check if your's fit with the default folder structure if not change it accordingly. Is your software organized in Modules as Maven expect it? What kind of Project do you have (EAR, WAR, ?). If start you have to write a pom and define the depenencies etc. and try to compile your project via Maven...

khmarbaise
+3  A: 

If you are new to Maven, I'd still suggest to start with Maven by Example, the "first" book of Sonatype.

This book is an example-driven introduction. If you are new to Maven, read this book first. It will introduce all of the basics and take you all the way up to a multi-module enterprise project.

Maven by Example is really not that big and reading it is definitely worth it. Sure, there are other tutorials around there and you could get started without reading it but the fact is that this book has been written for beginners and will give you the basis to understand how things work. It will just save you some time later.

Later, use Maven: The Complete Reference as... complete reference.

Pascal Thivent
Maven by Example is the one I missed and shouldn't have. Thanks.
Dave
+1  A: 

I personally got a lot of value out of "Better Builds with Maven". It is also free, which I like. http://repo.exist.com/dist/maestro/1.7.0/BetterBuildsWithMaven.pdf. The maestrodev site has a bunch of examples as well.

revdrjrr