mjeanroy / rollup-plugin-license

Rollup plugin to add license banner to the final bundle and output third party licenses

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Read also NOTICE file from the repository, as used/required by the Apache 2.0 license

mitar opened this issue · comments

First, thank you for this great plugin. It really nicely solves a big paint point of dealing with licenses.

Apache 2.0 license requires to bundle also any NOTICE file, if one exists in the repository, not just the LICENSE file. Could you please read that file as well and append it to licenseText, if it exists? Currently the code reads only LICENSE* file?

Hi @mitar,

Thanks for your report!

It's definitely doable, thanks I didn't know the Apache 2.0 licence required the NOTICE file to be bundled as well, would you have a link I can read?

It seems quite easy to do, the only question I have is if it should be an option, or not. Said differently:

  • I'm not sure it's desired by all users of this plugin, but it's a requirement by Apache 2.0, then it probably is.
  • I don't think adding the NOTICE would be a breaking change, but I might be wrong.

From the license:

If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License.

Hi @mitar,

I just published version 3.3.0 with this feature (the notice file will be included in the third party output).
Feel free to re-open if you find an issue :)

Awesome, thank you!