Skip to content

Commit d3cd73d

Browse files
committed
Add license check plugin to root pom. Disabled for the entire project, except for poms that override it (opendaylight, nvp)
1 parent 33eaa4f commit d3cd73d

File tree

4 files changed

+70
-27
lines changed

4 files changed

+70
-27
lines changed

LICENSE.header

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
Licensed to the Apache Software Foundation (ASF) under one
2-
or more contributor license agreements. See the NOTICE file
2+
or more contributor license agreements. See the NOTICE file
33
distributed with this work for additional information
4-
regarding copyright ownership. The ASF licenses this file
4+
regarding copyright ownership. The ASF licenses this file
55
to you under the Apache License, Version 2.0 (the
66
"License"); you may not use this file except in compliance
7-
with the License. You may obtain a copy of the License at
7+
with the License. You may obtain a copy of the License at
88

9-
http://www.apache.org/licenses/LICENSE-2.0
9+
http://www.apache.org/licenses/LICENSE-2.0
1010

1111
Unless required by applicable law or agreed to in writing,
1212
software distributed under the License is distributed on an
1313
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14-
KIND, either express or implied. See the License for the
14+
KIND, either express or implied. See the License for the
1515
specific language governing permissions and limitations
1616
under the License.

plugins/network-elements/nicira-nvp/pom.xml

+15
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,21 @@
3434
<filtering>true</filtering>
3535
</testResource>
3636
</testResources>
37+
<plugins>
38+
<plugin>
39+
<groupId>com.mycila</groupId>
40+
<artifactId>license-maven-plugin</artifactId>
41+
<executions>
42+
<execution>
43+
<id>cloudstack-checklicence</id>
44+
<phase>process-classes</phase>
45+
<goals>
46+
<goal>check</goal>
47+
</goals>
48+
</execution>
49+
</executions>
50+
</plugin>
51+
</plugins>
3752
</build>
3853

3954
<profiles>

plugins/network-elements/opendaylight/pom.xml

+4-22
Original file line numberDiff line numberDiff line change
@@ -48,35 +48,17 @@
4848
</testResources>
4949
<plugins>
5050
<plugin>
51-
<groupId>com.mycila.maven-license-plugin</groupId>
52-
<artifactId>maven-license-plugin</artifactId>
53-
<version>1.9.0</version>
51+
<groupId>com.mycila</groupId>
52+
<artifactId>license-maven-plugin</artifactId>
5453
<executions>
5554
<execution>
55+
<id>cloudstack-checklicence</id>
5656
<phase>process-classes</phase>
5757
<goals>
58-
<goal>format</goal>
58+
<goal>check</goal>
5959
</goals>
6060
</execution>
6161
</executions>
62-
<configuration>
63-
<strictCheck>true</strictCheck>
64-
<aggregate>true</aggregate>
65-
<header>../../../LICENSE.header</header>
66-
<mapping>
67-
<xml>XML_STYLE</xml>
68-
    <java>DOUBLESLASH_STYLE</java>
69-
    <clj>SEMICOLON_STYLE</clj>
70-
</mapping>
71-
<useDefaultExcludes>false</useDefaultExcludes>
72-
<excludes>
73-
<exclude>target/**</exclude>
74-
<exclude>.settings/**</exclude>
75-
<exclude>.checkstyle</exclude>
76-
<exclude>.project</exclude>
77-
<exclude>.classpath</exclude>
78-
</excludes>
79-
</configuration>
8062
</plugin>
8163
</plugins>
8264
</build>

pom.xml

+46
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,7 @@
8787
<cs.daemon.version>1.0.10</cs.daemon.version>
8888
<cs.jna.version>4.0.0</cs.jna.version>
8989
<cs.checkstyle.version>2.11</cs.checkstyle.version>
90+
<cs.mycila.license.version>2.5</cs.mycila.license.version>
9091
</properties>
9192

9293
<distributionManagement>
@@ -455,6 +456,19 @@
455456
</execution>
456457
</executions>
457458
</plugin>
459+
<plugin>
460+
<groupId>com.mycila</groupId>
461+
<artifactId>license-maven-plugin</artifactId>
462+
<executions>
463+
<execution>
464+
<id>cloudstack-checklicence</id>
465+
<phase>none</phase>
466+
<goals>
467+
<goal>check</goal>
468+
</goals>
469+
</execution>
470+
</executions>
471+
</plugin>
458472
</plugins>
459473
<pluginManagement>
460474
<plugins>
@@ -488,6 +502,38 @@
488502
<excludes>**\/deps\/,**\/test\/,**\/target\/,**\/bin\/,**\/*.xml,**\/*.ini,**\/*.sh,**\/*.bat,**\/awsapi\/,**\/XenServerJava\/,**\/apidoc\/</excludes>
489503
</configuration>
490504
</plugin>
505+
<plugin>
506+
<groupId>com.mycila</groupId>
507+
<artifactId>license-maven-plugin</artifactId>
508+
<version>${cs.mycila.license.version}</version>
509+
<executions>
510+
<execution>
511+
<id>cloudstack-checklicence</id>
512+
<phase>process-classes</phase>
513+
<goals>
514+
<goal>check</goal>
515+
</goals>
516+
</execution>
517+
</executions>
518+
<configuration>
519+
<strictCheck>true</strictCheck>
520+
<aggregate>true</aggregate>
521+
<header>LICENSE.header</header>
522+
<mapping>
523+
<xml>XML_STYLE</xml>
524+
    <java>DOUBLESLASH_STYLE</java>
525+
    <clj>SEMICOLON_STYLE</clj>
526+
</mapping>
527+
<useDefaultExcludes>false</useDefaultExcludes>
528+
<excludes>
529+
<exclude>**/target/**</exclude>
530+
<exclude>.settings/**</exclude>
531+
<exclude>.checkstyle</exclude>
532+
<exclude>.project</exclude>
533+
<exclude>.classpath</exclude>
534+
</excludes>
535+
</configuration>
536+
</plugin>
491537
<plugin>
492538
<artifactId>maven-clean-plugin</artifactId>
493539
<configuration>

0 commit comments

Comments
 (0)