Author: mck
Date: Sun Oct 1 00:01:59 2017
New Revision: 1810239
URL: http://svn.apache.org/viewvc?rev=1810239&view=rev
Log:
- Add checkstyle ruleset that works with Java8+
- Make Java9 the default build tool
- Make Java8 the minimum runtime
- Use animal-sniffer plugin to check Java9 is not used
- upgrade checkstyle, and make it part of the normal build reactor
- remove the maven-wagon stuff, as it's all svnpub now
Added:
tiles/maven/trunk/build/tiles_checks_v8.xml
- copied, changed from r1538331,
tiles/maven/trunk/build/tiles_checks_v5.xml
Modified:
tiles/maven/trunk/pom/pom.xml
Copied: tiles/maven/trunk/build/tiles_checks_v8.xml (from r1538331,
tiles/maven/trunk/build/tiles_checks_v5.xml)
URL:
http://svn.apache.org/viewvc/tiles/maven/trunk/build/tiles_checks_v8.xml?p2=tiles/maven/trunk/build/tiles_checks_v8.xml&p1=tiles/maven/trunk/build/tiles_checks_v5.xml&r1=1538331&r2=1810239&rev=1810239&view=diff
==============================================================================
--- tiles/maven/trunk/build/tiles_checks_v5.xml (original)
+++ tiles/maven/trunk/build/tiles_checks_v8.xml Sun Oct 1 00:01:59 2017
@@ -17,7 +17,6 @@
-->
<!DOCTYPE module PUBLIC "-//Puppy Crawl//DTD Check Configuration 1.2//EN"
"http://www.puppycrawl.com/dtds/configuration_1_2.dtd">
<module name="Checker">
- <property name="severity" value="warning"/>
<module name="TreeWalker">
<property name="cacheFile" value="${checkstyle.cache.file}"/>
<module name="JavadocMethod">
@@ -66,13 +65,11 @@
<module name="LeftCurly"/>
<module name="NeedBraces"/>
<module name="RightCurly"/>
- <module name="DoubleCheckedLocking"/>
<module name="EmptyStatement"/>
<module name="EqualsHashCode"/>
<module name="IllegalInstantiation"/>
<module name="InnerAssignment"/>
<module name="MissingSwitchDefault"/>
- <module name="RedundantThrows"/>
<module name="SimplifyBooleanExpression"/>
<module name="SimplifyBooleanReturn"/>
<module name="FinalClass"/>
Modified: tiles/maven/trunk/pom/pom.xml
URL:
http://svn.apache.org/viewvc/tiles/maven/trunk/pom/pom.xml?rev=1810239&r1=1810238&r2=1810239&view=diff
==============================================================================
--- tiles/maven/trunk/pom/pom.xml (original)
+++ tiles/maven/trunk/pom/pom.xml Sun Oct 1 00:01:59 2017
@@ -96,7 +96,6 @@
<developer>
<name>Greg Reddin</name>
<id>greddin</id>
- <email>greddin at apache.org</email>
<roles>
<role>PMC Member</role>
</roles>
@@ -209,22 +208,17 @@
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
- <source>1.7</source>
- <target>1.7</target>
+ <source>1.8</source>
+ <target>1.8</target>
</configuration>
</plugin>
- <plugin>
- <groupId>org.codehaus.mojo</groupId>
- <artifactId>wagon-maven-plugin</artifactId>
- <version>1.0-beta-5</version>
- </plugin>
</plugins>
</pluginManagement>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-enforcer-plugin</artifactId>
- <version>1.4.1</version>
+ <version>3.0.0-M1</version>
<executions>
<execution>
<id>enforce-java</id>
@@ -232,17 +226,37 @@
<configuration>
<rules>
<requireJavaVersion>
- <version>[1.8.0-144,1.9)</version>
+ <version>[9,10)</version>
</requireJavaVersion>
</rules>
</configuration>
</execution>
</executions>
</plugin>
+ <!-- Make sure Java 9 classes and methods aren't accidentally used -->
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>animal-sniffer-maven-plugin</artifactId>
+ <version>1.16</version>
+ <configuration>
+ <signature>
+ <groupId>org.codehaus.mojo.signature</groupId>
+ <artifactId>java18</artifactId>
+ <version>1.0</version>
+ </signature>
+ </configuration>
+ <executions>
+ <execution>
+ <goals>
+ <goal>check</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
<plugin>
<artifactId>maven-site-plugin</artifactId>
<!-- required for MSITE-683 -->
- <version>3.3</version>
+ <version>3.6</version>
</plugin>
<plugin>
<artifactId>maven-release-plugin</artifactId>
@@ -255,14 +269,31 @@
<autoVersionSubmodules>true</autoVersionSubmodules>
</configuration>
</plugin>
+ <plugin>
+ <artifactId>maven-checkstyle-plugin</artifactId>
+ <version>2.17</version>
+ <inherited>true</inherited>
+ <dependencies>
+ <dependency>
+ <groupId>com.puppycrawl.tools</groupId>
+ <artifactId>checkstyle</artifactId>
+ <version>8.2</version>
+ </dependency>
+ </dependencies>
+ <configuration>
+
<configLocation>http://svn.apache.org/repos/asf/tiles/maven/trunk/build/tiles_checks_v8.xml</configLocation>
+ </configuration>
+ <executions>
+ <execution>
+ <id>validate</id>
+ <phase>validate</phase>
+ <goals>
+ <goal>check</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
</plugins>
- <extensions>
- <extension>
- <groupId>org.apache.maven.wagon</groupId>
- <artifactId>wagon-ssh</artifactId>
- <version>2.12</version>
- </extension>
- </extensions>
</build>
<reporting>
@@ -275,8 +306,7 @@
<artifactId>maven-checkstyle-plugin</artifactId>
<version>2.17</version>
<configuration>
-
<configLocation>http://svn.apache.org/repos/asf/tiles/maven/trunk/build/tiles_checks_v5.xml
- </configLocation>
+
<configLocation>http://svn.apache.org/repos/asf/tiles/maven/trunk/build/tiles_checks_v8.xml</configLocation>
</configuration>
</plugin>
<plugin>
@@ -294,7 +324,7 @@
<artifactId>maven-pmd-plugin</artifactId>
<version>3.8</version>
<configuration>
- <targetJdk>1.7</targetJdk>
+ <targetJdk>1.8</targetJdk>
</configuration>
</plugin>
<plugin>
@@ -307,11 +337,8 @@
<aggregate>true</aggregate>
<excludePackageNames>org.apache.tiles.test</excludePackageNames>
<links>
-
<link>http://docs.oracle.com/javase/6/docs/api</link>
-
<link>http://docs.oracle.com/javaee/5/api</link>
-
<link>http://commons.apache.org/chain/apidocs</link>
-
<link>http://commons.apache.org/digester/commons-digester-1.6/docs/api</link>
- <link>http://www.slf4j.org/api</link>
+
<link>http://download.java.net/java/jdk9/docs/api/</link>
+
<link>http://docs.oracle.com/javaee/6/api</link>
</links>
<doclet>org.umlgraph.doclet.UmlGraphDoc</doclet>
<docletArtifact>