|
663 | 663 | <check/>
|
664 | 664 | </configuration>
|
665 | 665 | </plugin>
|
666 |
| - <plugin> |
667 |
| - <groupId>org.apache.maven.plugins</groupId> |
668 |
| - <artifactId>maven-checkstyle-plugin</artifactId> |
669 |
| - <version>2.17</version> |
670 |
| - <dependencies> |
671 |
| - <dependency> |
672 |
| - <groupId>com.puppycrawl.tools</groupId> |
673 |
| - <artifactId>checkstyle</artifactId> |
674 |
| - <version>6.16</version> |
675 |
| - </dependency> |
676 |
| - </dependencies> |
677 |
| - <executions> |
678 |
| - <execution> |
679 |
| - <id>checkstyle</id> |
680 |
| - <phase>validate</phase> |
681 |
| - <goals> |
682 |
| - <goal>check</goal> |
683 |
| - </goals> |
684 |
| - <configuration> |
685 |
| - <headerLocation>java.header</headerLocation> |
686 |
| - <configLocation>license-checks.xml</configLocation> |
687 |
| - <consoleOutput>true</consoleOutput> |
688 |
| - <failOnViolation>true</failOnViolation> |
689 |
| - <violationSeverity>error</violationSeverity> |
690 |
| - <failsOnError>true</failsOnError> |
691 |
| - <includeTestSourceDirectory>true</includeTestSourceDirectory> |
692 |
| - <excludes>com/google/cloud/*/v*/**</excludes><!-- We need to exclude autogenerated code --> |
693 |
| - </configuration> |
694 |
| - </execution> |
695 |
| - </executions> |
696 |
| - </plugin> |
697 | 666 | <plugin>
|
698 | 667 | <groupId>org.apache.maven.plugins</groupId>
|
699 | 668 | <artifactId>maven-site-plugin</artifactId>
|
|
968 | 937 | </plugins>
|
969 | 938 | </build>
|
970 | 939 | </profile>
|
| 940 | + |
| 941 | + <profile> |
| 942 | + <!-- Only run checkstyle plugin on Java 8+ (checkstyle artifact only supports Java 8+) --> |
| 943 | + <id>checkstyle-tests</id> |
| 944 | + <activation> |
| 945 | + <jdk>[1.8,)</jdk> |
| 946 | + </activation> |
| 947 | + <build> |
| 948 | + <plugins> |
| 949 | + <plugin> |
| 950 | + <groupId>org.apache.maven.plugins</groupId> |
| 951 | + <artifactId>maven-checkstyle-plugin</artifactId> |
| 952 | + <version>3.0.0</version> |
| 953 | + <dependencies> |
| 954 | + <dependency> |
| 955 | + <groupId>com.puppycrawl.tools</groupId> |
| 956 | + <artifactId>checkstyle</artifactId> |
| 957 | + <version>8.19</version> |
| 958 | + </dependency> |
| 959 | + </dependencies> |
| 960 | + <executions> |
| 961 | + <execution> |
| 962 | + <id>checkstyle</id> |
| 963 | + <phase>validate</phase> |
| 964 | + <goals> |
| 965 | + <goal>check</goal> |
| 966 | + </goals> |
| 967 | + <configuration> |
| 968 | + <headerLocation>java.header</headerLocation> |
| 969 | + <configLocation>license-checks.xml</configLocation> |
| 970 | + <consoleOutput>true</consoleOutput> |
| 971 | + <failOnViolation>true</failOnViolation> |
| 972 | + <violationSeverity>error</violationSeverity> |
| 973 | + <failsOnError>true</failsOnError> |
| 974 | + <includeTestSourceDirectory>true</includeTestSourceDirectory> |
| 975 | + <excludes>com/google/cloud/*/v*/**</excludes><!-- We need to exclude autogenerated code --> |
| 976 | + </configuration> |
| 977 | + </execution> |
| 978 | + </executions> |
| 979 | + </plugin> |
| 980 | + </plugins> |
| 981 | + </build> |
| 982 | + </profile> |
971 | 983 | </profiles>
|
972 | 984 | </project>
|
0 commit comments