Book Image

Apache Maven Cookbook

Book Image

Apache Maven Cookbook

Overview of this book

Table of Contents (18 chapters)
Apache Maven Cookbook
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

Index

A

  • aggregator project
    • about / How it works...
  • ANT
    • about / Running an ANT task
  • Ant
    • about / A brief comparison with other build automation tools
  • ANT task
    • creating / Running an ANT task, How it works..., There's more...
  • Artifactory / Changing the location of the Maven repository
  • assembly
    • creating / Creating an assembly, Getting ready, How it works..., There's more...

B

  • build automation tools
    • Make / A brief comparison with other build automation tools
    • Ant / A brief comparison with other build automation tools
  • Build Helper Maven plugin, goals
    • attach-artifact / There's more...
    • maven-version / There's more...

C

  • changelogs
    • generating, for site / Generating changelogs for a site, How it works...
  • Checkstyle plugin
    • about / Analyzing code with the Maven Checkstyle plugin
    • used, for analyzing code / How to do it..., How it works..., There's more...
  • checksumPolicy element / There's more...
  • clean lifecycle
    • about / How it works...
  • Clean plugin
    • using / Getting ready, How it works...
    • running, automatically / Cleaning automatically
    • deletion, skipping of working directory / Skipping the deletion of the working directory
    • additional folders/files, deleting / Deleting additional folders/files
  • Cobertura plugin
    • about / Analyzing code coverage with the Maven Cobertura plugin
    • used, for analyzing code coverage / How to do it..., There's more...
    • used, for generating test coverage / There's more...
  • code
    • analyzing, with PMD plugin / How to do it..., How it works..., There's more...
    • analyzing, with Checkstyle plugin / How to do it..., How it works..., There's more...
    • analyzing, with FindBugs plugin / How to do it..., How it works...
    • analyzing, with SonarQube plugin / Analyzing code with the Maven SonarQube plugin, Getting ready..., How to do it..., How it works...
  • code coverage
    • analyzing, with JaCoCo plugin / How to do it..., There's more...
    • analyzing, with Cobertura plugin / How to do it..., There's more...
  • code coverage reports
    • generating, for site / How to do it..., How it works...
  • code quality reports
    • generating, for site / Generating code quality reports for a site, How to do it...
  • command-line options, Maven
    • about / Understanding command-line options in Maven, Options
  • command-line options, modules
    • about / There's more...
    • -pl -projects / There's more...
    • -am / There's more...
    • -amd / There's more...
    • -rf / There's more...
  • compilation
    • about / Using the Maven Compiler plugin
    • skipping, of test sources / Skipping the compilation of test sources
  • compile phase / How it works...
  • compiler
    • modifying, used by Maven / Changing the compiler used by the Maven Compiler plugin, How it works...
  • Compiler plugin
    • using / How to do it..., How it works...
    • Java version, specifying for / Specifying the Java version for the Compiler plugin, How to do it...
  • complex project, transitive dependencies
    • reference link / Getting ready, Getting ready
  • configurations, Maven JAR plugin
    • in pom file / How it works...
  • constraints
    • controlling / Controlling the constraints, How to do it...
  • Copy/Paste Detector (CPD) / Analyzing code with the Maven PMD plugin
  • custom enforcer rules
    • reference link / There's more...
  • custom executable
    • running / Running a custom executable, There's more...

D

  • default lifecycle
    • about / How it works...
    • phases / How it works...
  • dependencies
    • downloading, to folder / Downloading dependencies into a folder, How it works...
    • installing, manually / Manually installing dependencies that are not available in a repository, How it works...
    • managing, Eclipse IDE used / How to do it..., There's more...
    • managing, NetBeans IDE used / Dependency management using NetBeans, How to do it...
    • managing, IntelliJ IDEA used / How to do it..., How it works...
  • dependency download errors
    • handling / Handling dependency download errors, How to do it...
  • dependency hell
    • avoiding / How to do it..., How it works..., There's more...
  • dependency management
    • about / Performing multi-module dependency management
  • dependency scopes
    • compile / How it works...
    • test / How it works...
    • runtime / How it works...
    • provided / How it works...
    • system / How it works...
    • import / How it works...
  • display-dependency-updates goal / How it works...
  • display-plugin-updates goal / How it works...
  • documentation
    • generating, with Site plugin / Documenting with the Maven Site plugin, How to do it..., How it works...

E

  • EAR files / Building an EAR project
  • EAR project
    • building / How to do it..., How it works...
  • Eclipse
    • about / Creating a new Maven project in Eclipse
    • new Maven project, creating in / Getting ready, How to do it..., How it works...
    • URL, for downloading / Getting ready
    • existing Maven project, importing in / Importing an existing Maven project in Eclipse, How to do it..., How it works...
    • used, for running Maven goals / Using Eclipse to run Maven goals, How it works...
  • Eclipse IDE
    • used, for managing dependencies / How to do it..., There's more...
  • enforcer plugin
    • about / How it works...
  • enforcer plugin, rules
    • requireOS / There's more...
    • requireFilesExist / There's more...
  • executable JAR
    • generating / Generating an executable JAR, How to do it..., How it works...
  • existing Maven project
    • importing, in Eclipse / Importing an existing Maven project in Eclipse, How to do it..., How it works...
    • importing, in NetBeans / Importing an existing Maven project in NetBeans, How to do it...
    • importing, in IntelliJ IDEA / Importing an existing Maven project in IntelliJ IDEA, How to do it..., How it works..., There's more...

F

  • Failsafe plugin
    • used, for running integration tests / Using the Maven Failsafe plugin to run integration tests, How to do it..., How it works...
  • filtering
    • performing, resources used / Filtering using resources, How it works...
  • FindBugs plugin
    • about / Analyzing code with the Maven FindBugs plugin
    • used, for analyzing code / How to do it..., How it works...
  • folder
    • dependencies, downloading to / Downloading dependencies into a folder, How it works...

G

  • Git setup link
    • URL / Getting ready
  • go-offline goal / How it works...
  • goals, JaCoCo plugin
    • prepare-agent / How it works...
    • report / How it works...

H

  • Help plugin
    • using / Using the Maven Help plugin, How to do it..., How it works...
  • Help plugin, goals
    • effective-pom / How it works...
    • all-profiles / How it works...
    • active-profiles / How it works...
  • HTTP Proxy Server
    • Maven, running behind / Running Maven behind an HTTP proxy server, How it works...

I

  • IDE
    • about / Introduction
  • in-project repository / There's more...
  • install-file goal / How it works...
  • integration tests
    • running, Failsafe plugin used / Using the Maven Failsafe plugin to run integration tests, How to do it..., How it works...
  • IntelliJ IDEA
    • about / Creating a new Maven project in IntelliJ IDEA
    • new Maven project, creating in / Creating a new Maven project in IntelliJ IDEA, How to do it...
    • URL, for downloading / Getting ready, Getting ready
    • Maven, customizing in / There's more...
    • existing Maven project, importing in / Importing an existing Maven project in IntelliJ IDEA, How to do it..., How it works..., There's more...
    • used, for running Maven goals / Using IntelliJ IDEA to run Maven goals, How to do it..., How it works...
    • used, for managing dependencies / How to do it..., How it works...

J

  • JaCoCo plugin
    • about / Analyzing code coverage with the Maven JaCoCo plugin
    • used, for analyzing code coverage / How to do it..., There's more...
  • JAR, of source code
    • generating / Generating a JAR of the source code, How to do it..., How it works..., There's more...
  • JAR, of test classes
    • generating / Generating a JAR of the test classes, How to do it..., How it works...
  • jar-no-fork goal / How it works...
  • JAR project
    • building / Building a JAR project, How to do it...
  • Java Development Kit (JDK)
    • about / Getting ready
  • Javadocs
    • generating, for site / Generating Javadocs for a site, How to do it..., How it works..., There's more...
  • Java Runtime Environment (JRE)
    • about / Getting ready
  • Java SE Downloads
    • URL / How to do it...
  • Java version
    • specifying, for Compiler plugin / Specifying the Java version for the Compiler plugin, How to do it...
    / How it works...
  • JDK
    • modifying, used by Maven / Changing the JDK used by Maven, How it works...
  • Jetty
    • web project, running with / Running a web project with Jetty, How to do it..., How it works..., There's more...
  • jetty server / There's more...
  • JUnit / How it works...
    • about / Using TestNG
  • JXR plugin
    • source references, generating with / Generating source references with the Maven JXR plugin, How to do it..., How it works..., There's more...

L

  • lifecycles, Maven
    • default / How it works...
    • clean / How it works...
    • site / How it works...
  • Linux
    • Maven, installing on / Installing Maven on Linux, Getting ready, How to do it..., How it works..., There's more...
  • localRepository element
    • about / The localRepository element
  • location
    • modifying, of Maven repository / Changing the location of the Maven repository, How it works...

M

  • Mac OS X
    • Maven, installing on / Installing Maven on Mac OS X, Getting ready, How to do it..., How it works...
  • Make
    • about / A brief comparison with other build automation tools
  • Maven
    • about / Introduction
    • installing, on Microsoft Windows / Installing Maven on Microsoft Windows, Getting ready, How to do it..., How it works...
    • URL / How to do it..., How to do it..., How to do it...
    • installing, on Mac OS X / Installing Maven on Mac OS X, Getting ready, How to do it..., How it works...
    • installing, on Linux / Installing Maven on Linux, Getting ready, How to do it..., How it works..., There's more...
    • simple project, creating with / Creating a simple project with Maven, How to do it..., How it works...
    • simple project, building with / Building a simple project with Maven, How it works...
    • running, behind HTTP Proxy Server / Running Maven behind an HTTP proxy server, How it works...
    • customizing, in IntelliJ IDEA / There's more...
    • lifecycle / Getting ready
    • goals / Getting ready
    • phases / Getting ready, How it works...
    • settings configurations / How it works..., The proxies element, The pluginRepositories element
    • command-line options / Understanding command-line options in Maven, Options
    • properties, using in / Using properties in Maven, How it works...
    • configuring, for searching plugin / Configuring Maven to search for plugins, How it works...
  • Maven Central Repository
    • about / Introduction
  • Maven dependencies
    • updates, determining to / Determining updates to Maven dependencies, How it works...
  • Maven goals
    • running, Eclipse used / Using Eclipse to run Maven goals, How it works...
    • running, NetBeans used / Using NetBeans to run Maven goals, How it works...
    • running, IntelliJ IDEA used / Using IntelliJ IDEA to run Maven goals, How to do it..., How it works...
  • Maven output
    • verbosity, controlling of / Controlling the verbosity of the Maven output, How it works...
  • Maven plugin
    • updates, determining to / Determining updates to Maven plugin AntRun, How to do it..., How it works..., There's more...
  • Maven profile
    • adding / Adding a new Maven profile
    • activating / Activating/deactivating a Maven profile, How it works...
    • deactivating / Activating/deactivating a Maven profile, Getting ready, How it works...
  • Maven profiles
    • about / Understanding Maven profiles, How it works...
    • Per Project profile / How it works...
    • Per User profile / How it works...
    • Global profile / How it works...
  • Maven project
    • releasing / Releasing a Maven project, How to do it..., How it works...
  • Maven repositories
    • local / Changing the location of the Maven repository
    • remote / Changing the location of the Maven repository
    • mirrors / Changing the location of the Maven repository
  • Maven repository
    • location, modifying of / Changing the location of the Maven repository, How it works...
  • Maven settings
    • about / How to do it...
  • Maven version / How it works...
  • Microsoft Windows
    • Maven, installing on / Installing Maven on Microsoft Windows, Getting ready, How to do it..., How it works...
  • mirrors element
    • about / The mirrors element
  • module
    • about / Understanding project aggregation
  • module element / There's more...
  • modules
    • building, selectively / Selectively building modules, How it works...
  • multimodule dependency management
    • performing / Performing multi-module dependency management, How to do it..., How it works...
  • multimodule plugin management
    • performing / How to do it..., How it works..., There's more...
  • multimodule projects
    • reporting for / Reporting for multi-module projects, How it works..., There's more...

N

  • NetBeans
    • about / Creating a new Maven project in NetBeans
    • URL / Getting ready, Getting ready
    • new Maven project, creating in / How to do it..., How it works...
    • existing Maven project, importing in / Importing an existing Maven project in NetBeans, How to do it...
    • used, for running Maven goals / Using NetBeans to run Maven goals, How it works...
  • NetBeans IDE
    • used, for managing dependencies / Dependency management using NetBeans, How to do it...
  • new Maven project
    • creating, in Eclipse / Getting ready, How to do it..., How it works...
    • creating, in NetBeans / How to do it..., How it works...
    • creating, in IntelliJ IDEA / Creating a new Maven project in IntelliJ IDEA, How to do it...
  • Nexus / Changing the location of the Maven repository

O

  • offline element
    • about / The offline element
  • offline mode
    • working in / Working in offline mode, How to do it..., How it works...
  • Oracle Java download page
    • URL / Getting ready, Getting ready

P

  • package phase / How it works...
  • phases, default lifecycle
    • validate / How it works...
    • process-resources / How it works...
    • compile / How it works...
    • test / How it works...
    • package / How it works...
    • integration-test / How it works...
    • verify / How it works...
    • install / How it works...
    • deploy / How it works...
  • placeholders
    • about / How it works...
  • platform-independent builds
    • source encoding, specifying for / Specifying source encoding for platform-independent builds, How it works...
  • pluginGroups / There's more...
  • pluginManagement
    • about / Performing multi-module plugin management
  • pluginRepositories element
    • about / The pluginRepositories element
  • PMD plugin
    • about / Analyzing code with the Maven PMD plugin
    • used, for analyzing code / How to do it..., How it works..., There's more...
  • pom file
    • about / How to do it..., How it works...
  • POM project
    • building / Building a pom project, How it works..., There's more...
  • profile feature
    • used, for building modules / Selectively building modules, How it works...
  • project aggregation
    • about / Understanding project aggregation, How to do it..., How it works...
    • combining, with project inheritance / Combining inheritance and aggregation, How to do it..., How it works...
  • project inheritance
    • about / Understanding project inheritance, How to do it..., How it works..., There's more...
    • combining, with project aggregation / Combining inheritance and aggregation, How to do it..., How it works...
  • project working directory
    • about / Using the Maven Clean plugin
  • properties
    • using, in Maven / Using properties in Maven, How it works...
  • proxies element
    • about / The proxies element

R

  • relativePath element / There's more...
  • report, of dependencies
    • obtaining / Getting a report of dependencies, How it works..., There's more...
  • repositories, for release version / There's more...
  • repositories, for snapshot version / There's more...
  • repositories element
    • about / The repositories element
  • resources
    • used, for performing filtering / Filtering using resources, How it works...
    • including / Getting ready, How to do it...
    • excluding / Getting ready, How to do it...
  • Resources plugin
    • about / Using the Maven Resources plugin
    • using / How to do it..., How it works...

S

  • SCM plugin
    • using / Using the Maven SCM plugin, How to do it...
    • operations / There's more...
  • scm tag, entries
    • connection / How it works...
    • developerConnection / How it works...
    • url / How it works...
  • scope, of dependency
    • selecting / Choosing the scope of dependency, How it works...
  • selective reports
    • generating / Generating selective reports, How to do it..., How it works...
  • servers element
    • about / The servers element
  • settings configurations, Maven
    • localRepository element / The localRepository element
    • offline element / The offline element
    • proxies element / The proxies element
    • mirrors element / The mirrors element
    • repositories element / The repositories element
    • pluginRepositories element / The pluginRepositories element
    • servers element / The servers element
  • Simple Logging Facade for Java (slf4j) / How it works...
  • simple project
    • creating, with Maven / Creating a simple project with Maven, How to do it..., How it works...
    • building, with Maven / Building a simple project with Maven, How it works...
  • site
    • Javadocs, generating for / Generating Javadocs for a site, How to do it..., How it works..., There's more...
    • source cross-reference, generating for / Generating source cross-reference for a site, How it works...
    • unit test reports, generating for / Generating unit test reports for a site, How it works...
    • code coverage reports, generating for / How to do it..., How it works...
    • code quality reports, generating for / Generating code quality reports for a site, How to do it...
    • deploying / Deploying a site, How it works...
    • testing, before deployment / There's more...
    • changelogs, generating for / Generating changelogs for a site, How it works...
  • site documentation
    • Sonar report, linking from / There's more...
  • site lifecycle
    • about / How it works...
  • Site plugin
    • documenting with / Documenting with the Maven Site plugin, How to do it..., How it works...
    • configurations, for customizations / There's more...
  • SNAPSHOT
    • about / How it works...
  • SNAPSHOT dependencies
    • about / Understanding SNAPSHOT dependencies, How to do it..., How it works...
  • snapshot repositories / How it works...
  • software configuration management (SCM)
    • about / Introduction
  • SonarQube plugin
    • used, for analyzing code / Analyzing code with the Maven SonarQube plugin, Getting ready..., How to do it..., How it works...
    • URL, for downloading / Getting ready...
  • Sonar report
    • linking, from site documentation / There's more...
  • source cross-reference
    • generating, for site / Generating source cross-reference for a site, How it works...
  • source encoding
    • specifying, for platform-independent builds / Specifying source encoding for platform-independent builds, How it works...
  • source references
    • generating, with JXR plugin / Generating source references with the Maven JXR plugin, How to do it..., How it works..., There's more...
  • sources
    • excluding / Including and excluding source files and folders, How it works...
    • including / Including and excluding source files and folders, How it works...
  • standard directory layout
    • about / Understanding the standard directory layout, How it works...
  • Surefire plugin
    • used, for running unit tests / How to do it..., How it works...

T

  • test coverage
    • generating, Cobertura plugin used / There's more...
  • TestNG
    • using / Using TestNG
    • URL / Using TestNG
  • test phase / How it works...
  • test resources
    • copying, selectively / There's more...
  • tests
    • skipping / Skipping tests
  • test sources
    • compilation, skipping of / Skipping the compilation of test sources
  • Tomcat
    • web project, running with / Running a web project with Tomcat, How it works..., There's more...

U

  • unique builds
    • generating / Generating unique builds, How to do it..., How it works...
  • unit test reports
    • generating, for site / Generating unit test reports for a site, How it works...
  • unit tests
    • running, Surefire plugin used / How to do it..., How it works...
  • unused/undeclared dependencies
    • detecting / How to do it..., How it works...
  • updates
    • determining, to Maven plugin / Determining updates to Maven plugin AntRun, How to do it..., How it works..., There's more...
    • determining, to Maven dependencies / Determining updates to Maven dependencies, How it works...

V

  • validate phase / How it works...
  • verbosity
    • controlling, of Maven output / Controlling the verbosity of the Maven output, How it works...

W

  • WAR plugin / There's more...
  • WAR project
    • building / Building a WAR project, How to do it..., How it works...
  • web project
    • running, with Jetty / Running a web project with Jetty, How to do it..., How it works..., There's more...
    • running, with Tomcat / Running a web project with Tomcat, How it works..., There's more...