-
-
Notifications
You must be signed in to change notification settings - Fork 26.6k
03. Coding conventions
Ilkka Seppälä edited this page Oct 3, 2015
·
7 revisions
Format the code according to Google Java Style Guide
The coding conventions can be automatically checked with Maven Checkstyle plugin. By default it is switched off, but can be easily switched on by altering its configuration in the main pom.xml
.
<!--checkstyle plug-in. checking against googles styles
see config at checkstyle.xml-->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-checkstyle-plugin</artifactId>
<version>2.15</version>
<executions>
<execution>
<id>validate</id>
<goals>
<goal>check</goal>
</goals>
<phase>validate</phase>
<configuration>
<configLocation>checkstyle.xml</configLocation>
<encoding>UTF-8</encoding>
<consoleOutput>false</consoleOutput>
<failsOnError>false</failsOnError>
</configuration>
</execution>
</executions>
</plugin>