提交 8dca6b88 编写于 作者: K Kohsuke Kawaguchi

Making it easy to activate the animal-sniffer Java5 check.

I originally attempted to define this in a profile that can be activated
from a child POM, but looking at MNG-3228
<http://jira.codehaus.org/browse/MNG-3228>, it appears that such use of
profiles aren't possible.

So I'm falling back to the <pluginManagement>, which can be activated
via the following fragment in build/plugins/plugin:

<plugin>
  <groupId>org.codehaus.mojo</groupId>
  <artifactId>animal-sniffer-maven-plugin</artifactId>
  <!-- details defined in the parent POM -->
</plugin>
上级 97a51a4f
......@@ -86,16 +86,15 @@
<version>2.4</version>
<scope>provided</scope>
</dependency>
<dependency>
<!-- for JRE requirement check annotation -->
<groupId>org.codehaus.mojo</groupId>
<artifactId>animal-sniffer-annotations</artifactId>
<version>1.7</version>
<scope>provided</scope>
<optional>true</optional><!-- no need to have this at runtime -->
</dependency>
</dependencies>
<!--dependencyManagement>
<dependencies>
<dependency>
<groupId>org.jenkins-ci.main</groupId>
<artifactId>maven-plugin</artifactId>
<version>1.395</version>
</dependency>
</dependencies>
</dependencyManagement-->
<build>
<!--
......@@ -250,6 +249,27 @@
</additionalProjectnatures>
</configuration>
</plugin>
<plugin>
<!-- make sure our code doesn't have 1.6 dependencies except where we know it -->
<groupId>org.codehaus.mojo</groupId>
<artifactId>animal-sniffer-maven-plugin</artifactId>
<version>1.7</version>
<executions>
<execution>
<goals>
<goal>check</goal>
</goals>
<phase>test</phase>
<configuration>
<signature>
<groupId>org.codehaus.mojo.signature</groupId>
<artifactId>java15</artifactId>
<version>1.0</version>
</signature>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</pluginManagement>
</build>
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册