rvesse commented on issue #3589:
URL: https://github.com/apache/jena/issues/3589#issuecomment-3737828487
> I'm getting closer to changing the license headers. For the actual change,
but after that, the `com.mycila:license-maven-plugin` can be used to check
(probably not automatically as its handling of sub-modules seems to require
absolute file names).
Typically the way I've "hacked" around this in the past is to define the
path to the expected license text using a Maven property in the plugin
configuration e.g.
```xml
<header>${license.header.path}/header.txt</header>
```
And then in each sub-module you redefine the property appropriately for that
module e.g. for the root `pom.xml`
```xml
<license.header.path>${project.basedir}</license.header.path>
```
For sub-modules use `.parent` to refer to parent module e.g.
```xml
<license.header.path>${project.parent.basedir}</license.header.path>
```
Multiple levels of `.parent` can be used for more deeply nested sub-modules
e.g.
```xml
<license.header.path>${project.parent.parent.basedir}</license.header.path>
```
Then the only gotcha becomes ensuring that you remembered to set the
property correctly in every child module which is a one-time thing unless you
start reorganising how modules are structured in your repository
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]