license-maven-plugin
license-maven-plugin copied to clipboard
Use of missingFile in multi-module projects
I have a few large multi-module projects, where I'd like to report on the 3rd-party licenses being used. I use mvn license:aggregate-add-third-party license:aggregate-third-party-report
for that.
From debugging I noticed that, even though I run in aggregation mode, the plugin expects the missingFile to live in the submodule. I was a bit surprised by that. Somehow I hoped I could write such a file once, for my whole repository, and use it for every module.
Are users supposed to write such a file in every child module? If not, I'd be happy to provide a little patch that always uses the one missingFile that lives in the project root.
Hi Maarten,
I am currently in the process of introducing the license plugin in our stack. It's a large multi-module stack as well. I do not encounter the problem you are reporting. I use the following configuration directive:
<missingFile>${maven.multiModuleProjectDirectory}/missing-THIRD-PARTY.properties</missingFile>
Maybe you can also use ${maven.multiModuleProjectDirectory}
?
With kind regards,
Jurrie
Hi Jurrie,
Thanks for this suggestion. I am no longer involved with the large multi-module project where I was seeing this issue. This means I'm not able to verify if your proposed solution works. I've forwarded your comment to somebody who (as far as I know) is still working on that project.
@Jurrie Thank! That was the key! As this file is also only being read (as far as I know) this should work flawlessly.
Using a central place for the THIRD-PARTY.txt is another topic...as the file seems to not get merged it would be overwritten for each module the add-third-party fork is being executed (my guess).