1 / 10

Introduction to Maven 2

Introduction to Maven 2. Basics. Convention over Configuration Declarative project management DRY. Build Lifecycles. Default Site Clean. Dependency Management. Declarative Transitive 3 qualifiers per dependency GroupId AritfactId Version Coping with Sun jars. Repositories.

webb
Download Presentation

Introduction to Maven 2

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Introduction to Maven 2

  2. Basics • Convention over Configuration • Declarative project management • DRY

  3. Build Lifecycles • Default • Site • Clean

  4. Dependency Management • Declarative • Transitive • 3 qualifiers per dependency • GroupId • AritfactId • Version • Coping with Sun jars

  5. Repositories • Place where all jars are stored • Local • Network / proxy • Central

  6. Archetypes • Project templates • Available for various project types • DEMO – create sample JSF app • mvn archetype:create -DarchetypeGroupId=org.apache.myfaces.maven \ -DarchetypeArtifactId=maven-archetype-myfaces \ -DarchetypeVersion=1.0-SNAPSHOT \ -DgroupId=myAppId \ -DartifactId=testApp

  7. Reports • Monitor code health • Metrics • Code Coverage • View codebase as a webpage • Track changes

  8. Mavenizing your project • Modify build section: • <build> <sourceDirectory>srcDir</sourceDirectory> <testSourceDirectory>testDir</testSourceDirectory>… </build>

  9. Multi – module projects • Use <dependencyManagement> to make your life easier • mvn install needed w/ inherited test classes • Let’s look at Terracotta.org’s codebase

  10. Resources • http://maven.apache.org • http://del.icio.us/jimbethancourt/maven

More Related