Introduction
maven-license-plugin is a Maven 2 plugin that help you managing license headers in source files.
Basically, when you are developing a project either in open source or in a company, you often need to add at the top of your source files a license to protect your work.
I didn't find any maven plugin on Internet to help you maintain these license headers. By maintaining, i mean checking if the header is here or not, generating a report and of course having the possibility to update / reformat missing license headers.
I only found RAT Maven plugin but this plugin only does a check.
Features
* Check : check if header is missing in some source file
* Reformat : add headers if missing
* Remove : can remove existing header
* Update : update existing header with a new one
* Custom mappings : enables easy support of new file extensions
* Variable replacement : You can add some variable in your header, such as ${year} , ${owner} and they will be replaced by the corresponding values taken from the pom or system properties.
Be up to date !
For the most recent version, see the Release Notes.
You can also subscribe to the google group mailing lists or RSS feeds to get the latest announcements, issues updates, svn updates, ... See the mailing lists section .
How to use and configure the plugin
The usage of the plugin is very simple. It is described in detail in the How To page .
To configure the plugin, see the configuration reference guide .
You can also have a check on the maven website of this plugin at http://mathieu.carbou.free.fr/p/maven-license-plugin/plugin-info.html
Supported formats
All listed there
variable replacement in header
You can define some variable in your header, and they will be replaced when the header file will be read. The values of the properties are taken first from the command line (java system properties), then from the plugin properties, then from the system properties.
See the configuration reference guide to see how to use it.
Getting help
* Maven 2 project website, with plugin description: http://mathieu.carbou.free.fr/p/maven-license-plugin/plugin-info.html
Other interesting projects
* XML Tool : http://code.google.com/p/xmltool/
* Mycila : http://code.mycila.com/