license:aggregate-add-third-party

Full name:

org.kuali.maven.plugins:license-maven-plugin:1.5-kuali:aggregate-add-third-party

Description:

This aggregator goal (will be executed only once and only on pom projects) executed the add-third-party on all his modules (in a parellel build cycle) then aggreates all the third-party files in final one in the pom project.

Attributes:

  • Requires a Maven project to be executed.
  • Executes as an aggregator plugin.
  • Since version: 1.0.
  • Binds by default to the lifecycle phase: generate-resources.
  • Invokes the execution of this plugin's goal add-third-party prior to executing itself.

Required Parameters

Name Type Since Description
outputDirectory File 1.0 Directory where to generate files.
Default value is: ${project.build.directory}/generated-sources/license.
project MavenProject 1.0 The reacted project.
Default value is: ${project}.
thirdPartyFilename String 1.0 File where to wirte the third-party file.
Default value is: THIRD-PARTY.txt.

Optional Parameters

Name Type Since Description
artifactLicenseMapping String 1.0 Location of a properties file mapping artifacts that are published with no license to the license that should be used for them. This supports classpath notation and any other type of URL Spring 3.1 resource loading can understand.
Default value is: THIRD-PARTY.properties.
bundleThirdPartyPath String 1.0 The path of the bundled third party file to produce when generateBundle is on.

Note: This option is not available for pom module types.
Default value is: META-INF/${project.artifactId}-THIRD-PARTY.txt.
encoding String 1.0 Encoding used to read and writes files.

Note: If nothing is filled here, we will use the system property file.encoding.
Default value is: ${project.build.sourceEncoding}.
excludedArtifacts String 1.0 A filter to exclude some ArtifactsIds
excludedGroups String 1.0 A filter to exclude some GroupIds
excludedScopes String 1.0 A filter to exclude some scopes.
Default value is: system.
failIfWarning boolean 1.0 A flag to fail the build if at least one dependency was detected without a license.
Default value is: false.
force boolean 1.0 To force generation of the third-party file even if every thing is up to date.
Default value is: false.
generateBundle boolean 1.0 A flag to copy a bundled version of the third-party file. This is usefull to avoid for a final application collision name of third party file.

The file will be copied at the bundleThirdPartyPath location.
Default value is: false.
groupByLicense boolean 1.0 A flag to change the grouping of the generated THIRD-PARTY file.

By default, group by dependecies.

If sets to true, the it will group by license type.
Default value is: false.
includeTransitiveDependencies boolean 1.0 Include transitive dependencies when downloading license files.
Default value is: true.
includedArtifacts String 1.0 A filter to include only some ArtifactsIds
includedGroups String 1.0 A filter to include only some GroupIds
includedScopes String 1.0 A filter to include only some scopes, if let empty then all scopes will be used (no filter).
licenseMerges List 1.0 To merge licenses in final file.

Each entry represents a merge (first license is main license to keep), licenses are separated by |.

Example :

<licenseMerges>
<licenseMerge>The Apache Software License|Version 2.0,Apache License, Version 2.0</licenseMerge>
</licenseMerges>
</pre>

missingFile File 1.0 The file where to fill the license for dependencies with unknown license.
Default value is: src/license/THIRD-PARTY.properties.
useMissingFile boolean 1.0 A flag to use the missing licenses file to consolidate the THID-PARTY file.
Default value is: false.
verbose boolean 1.0 Flag to activate verbose mode.

Note: Verbose mode is always on if you starts a debug maven instance (says via -X).
Default value is: ${maven.verbose}.

Parameter Details

artifactLicenseMapping:

Location of a properties file mapping artifacts that are published with no license to the license that should be used for them. This supports classpath notation and any other type of URL Spring 3.1 resource loading can understand.
  • Type: java.lang.String
  • Since: 1.0
  • Required: No
  • Expression: ${license.artifactLicenseMapping}
  • Default: THIRD-PARTY.properties

bundleThirdPartyPath:

The path of the bundled third party file to produce when generateBundle is on.

Note: This option is not available for pom module types.
  • Type: java.lang.String
  • Since: 1.0
  • Required: No
  • Expression: ${license.bundleThirdPartyPath}
  • Default: META-INF/${project.artifactId}-THIRD-PARTY.txt

encoding:

Encoding used to read and writes files.

Note: If nothing is filled here, we will use the system property file.encoding.
  • Type: java.lang.String
  • Since: 1.0
  • Required: No
  • Expression: ${license.encoding}
  • Default: ${project.build.sourceEncoding}

excludedArtifacts:

A filter to exclude some ArtifactsIds
  • Type: java.lang.String
  • Since: 1.0
  • Required: No
  • Expression: ${license.excludedArtifacts}

excludedGroups:

A filter to exclude some GroupIds
  • Type: java.lang.String
  • Since: 1.0
  • Required: No
  • Expression: ${license.excludedGroups}

excludedScopes:

A filter to exclude some scopes.
  • Type: java.lang.String
  • Since: 1.0
  • Required: No
  • Expression: ${license.excludedScopes}
  • Default: system

failIfWarning:

A flag to fail the build if at least one dependency was detected without a license.
  • Type: boolean
  • Since: 1.0
  • Required: No
  • Expression: ${license.failIfWarning}
  • Default: false

force:

To force generation of the third-party file even if every thing is up to date.
  • Type: boolean
  • Since: 1.0
  • Required: No
  • Expression: ${license.force}
  • Default: false

generateBundle:

A flag to copy a bundled version of the third-party file. This is usefull to avoid for a final application collision name of third party file.

The file will be copied at the bundleThirdPartyPath location.
  • Type: boolean
  • Since: 1.0
  • Required: No
  • Expression: ${license.generateBundle}
  • Default: false

groupByLicense:

A flag to change the grouping of the generated THIRD-PARTY file.

By default, group by dependecies.

If sets to true, the it will group by license type.
  • Type: boolean
  • Since: 1.0
  • Required: No
  • Expression: ${license.groupByLicense}
  • Default: false

includeTransitiveDependencies:

Include transitive dependencies when downloading license files.
  • Type: boolean
  • Since: 1.0
  • Required: No
  • Default: true

includedArtifacts:

A filter to include only some ArtifactsIds
  • Type: java.lang.String
  • Since: 1.0
  • Required: No
  • Expression: ${license.includedArtifacts}

includedGroups:

A filter to include only some GroupIds
  • Type: java.lang.String
  • Since: 1.0
  • Required: No
  • Expression: ${license.includedGroups}

includedScopes:

A filter to include only some scopes, if let empty then all scopes will be used (no filter).
  • Type: java.lang.String
  • Since: 1.0
  • Required: No
  • Expression: ${license.includedScopes}

licenseMerges:

To merge licenses in final file.

Each entry represents a merge (first license is main license to keep), licenses are separated by |.

Example :

<licenseMerges>
<licenseMerge>The Apache Software License|Version 2.0,Apache License, Version 2.0</licenseMerge>
</licenseMerges>
</pre>
  • Type: java.util.List
  • Since: 1.0
  • Required: No

missingFile:

The file where to fill the license for dependencies with unknown license.
  • Type: java.io.File
  • Since: 1.0
  • Required: No
  • Expression: ${license.missingFile}
  • Default: src/license/THIRD-PARTY.properties

outputDirectory:

Directory where to generate files.
  • Type: java.io.File
  • Since: 1.0
  • Required: Yes
  • Expression: ${license.outputDirectory}
  • Default: ${project.build.directory}/generated-sources/license

project:

The reacted project.
  • Type: org.apache.maven.project.MavenProject
  • Since: 1.0
  • Required: Yes
  • Default: ${project}

thirdPartyFilename:

File where to wirte the third-party file.
  • Type: java.lang.String
  • Since: 1.0
  • Required: Yes
  • Expression: ${license.thirdPartyFilename}
  • Default: THIRD-PARTY.txt

useMissingFile:

A flag to use the missing licenses file to consolidate the THID-PARTY file.
  • Type: boolean
  • Since: 1.0
  • Required: No
  • Expression: ${license.useMissingFile}
  • Default: false

verbose:

Flag to activate verbose mode.

Note: Verbose mode is always on if you starts a debug maven instance (says via -X).
  • Type: boolean
  • Since: 1.0
  • Required: No
  • Expression: ${license.verbose}
  • Default: ${maven.verbose}