class LicenseExtension extends java.lang.Object
Represents the Gradle extension for configuring the settings for the Licenser plugin.
| Type | Name and description |
|---|---|
java.lang.String |
charsetThe charset to read/write the files with. |
org.gradle.api.tasks.util.PatternFilterable |
filterThe filter to apply to the source files of the sourceSets. |
java.io.File |
headerThe path to the file containing the license header. |
boolean |
ignoreFailuresWhether to ignore failures and only warn about license violations instead of failing the build. |
java.util.List<java.lang.String> |
keywordsThe (case-insensitive) keywords that identify a comment as license header. |
boolean |
newLineWhether to insert an empty line after the license header. |
java.util.Collection<org.gradle.api.tasks.SourceSet> |
sourceSetsThe source sets to scan for files with license headers. |
HeaderFormatRegistry |
styleThe style mappings from file extension to the type of style of the comment header for the license header. |
| Constructor and description |
|---|
LicenseExtension
() |
| Type | Name and description |
|---|---|
void |
style(groovy.lang.Closure closure)' } |
| Methods inherited from class | Name |
|---|---|
class java.lang.Object |
java.lang.Object#wait(long, int), java.lang.Object#wait(long), java.lang.Object#wait(), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll() |
The charset to read/write the files with.
By default this is UTF-8.
The filter to apply to the source files of the sourceSets. By default this only includes a few excludes for binary files or files without standardized comment formats.
The path to the file containing the license header.
By default this is the LICENSE file in the project directory.
Whether to ignore failures and only warn about license violations
instead of failing the build.
By default this is false.
The (case-insensitive) keywords that identify a comment as license header. By default this includes only the words "Copyright" and "License".
Whether to insert an empty line after the license header.
By default this is true.
The source sets to scan for files with license headers. By default this includes all source sets of the project.
The style mappings from file extension to the type of style of the comment header for the license header. By default this includes mappings and styles for the most common file types.
Groovy Documentation