Static Code Analysis Custom Check style with Maven build CQ5/AEM

Any Maven Build tool can use Check style for code analysis.

List of items to be touched.

<build>
<pluginManagement>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-checkstyle-plugin</artifactId>
<version>2.9.1</version>
</plugin>
</plugins>
</pluginManagement>
</build>

  • You are done with your changes. Run your command like “mvn clean install checkstyle:checkstyle” since you provided your config for google_checks…it will use the same if you remove the properties it will use out of box and your code analysis report would be created under /target/site as html and XML.

Please let me know if you have any question.

Advertisement

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s