add license-check profile and header template file

This commit is contained in:
Jesse McConnell 2012-08-16 15:26:38 -05:00
parent 6dbef17e44
commit 8dc7a7b1d7
2 changed files with 57 additions and 0 deletions

15
header-template.txt Normal file
View File

@ -0,0 +1,15 @@
========================================================================
Copyright (c) ${copyright-range} Mort Bay Consulting Pty. Ltd.
------------------------------------------------------------------------
All rights reserved. This program and the accompanying materials
are made available under the terms of the Eclipse Public License v1.0
and Apache License v2.0 which accompanies this distribution.
The Eclipse Public License is available at
http://www.eclipse.org/legal/epl-v10.html
The Apache License v2.0 is available at
http://www.opensource.org/licenses/apache2.0.php
You may elect to redistribute this code under either of these licenses.
========================================================================

42
pom.xml
View File

@ -727,5 +727,47 @@
</plugins>
</build>
</profile>
<profile>
<id>license-check</id>
<build>
<plugins>
<plugin>
<inherited>false</inherited>
<groupId>com.mycila.maven-license-plugin</groupId>
<artifactId>maven-license-plugin</artifactId>
<version>1.10.b1</version>
<configuration>
<header>header-template.txt</header>
<failIfMissing>true</failIfMissing>
<aggregate>true</aggregate>
<strictCheck>true</strictCheck>
<properties>
<copyright-range>${project.inceptionYear}-2012</copyright-range>
</properties>
<mapping>
<java>DOUBLESLASH_STYLE</java>
</mapping>
<includes>
<include>**/*.java</include>
</includes>
<excludes>
<exclude>jetty-util/src/main/java/org/eclipse/jetty/util/security/UnixCrypt.java</exclude>
<exclude>jetty-policy/src/main/java/org/eclipse/jetty/policy/loader/DefaultPolicyLoader.java</exclude>
<exclude>jetty-policy/src/main/java/org/eclipse/jetty/policy/loader/PolicyFileScanner.java</exclude>
</excludes>
</configuration>
<executions>
<execution>
<id>check-headers</id>
<phase>verify</phase>
<goals>
<goal>check</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
</profiles>
</project>