Fork me on GitHub

CodeNarc Maven Plugin

The CodeNarc Maven Plugin provides a way to incorporate the CodeNarc static Groovy analysis tool into your Maven build. It can be used either as a reporting or a regular plugin, with optional HTML report generation. See a sample generated report here.

The current version of the plugin uses CodeNarc 1.5.

Feel free to report bugs and submit feature requests to GitHub.

Goals Overview

The CodeNarc Maven Plugin has two goals:

  • codenarc:verify - performs CodeNarc analysis, and optionally fails the build if specified quality criteria are not met
  • codenarc:codenarc - creates a CodeNarc report (implies the execution of the codenarc:verify goal)

Usage

Detailed usage instructions can be found on the usage page. Also, make sure to check out the FAQ. More complex use cases and sample reports are shown in the Examples section. A couple of working example projects can also be found in the source code repository.

Examples