Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Collect more additional legal files #85

Open
mlinksva opened this issue Oct 1, 2018 · 2 comments
Open

Collect more additional legal files #85

mlinksva opened this issue Oct 1, 2018 · 2 comments

Comments

@mlinksva
Copy link
Contributor

@mlinksva mlinksva commented Oct 1, 2018

Currently licensed includes files matching:

LEGAL_FILES = /\A(AUTHORS|COPYING|NOTICE|LEGAL)(?:\..*)?\z/i

I think COPYING is superfluous, see #84, but there are some other files (also with any extension) that often include legal notices that would be useful to automatically collect, eg:

  • LICENSES, NOTICES (plural)
  • THIRD-PARTY-LICENSE (variations including 3rd, no delimiter, underscore delimiter, notice, plural)

I can probably suggest a semi-sane regex and tests for this, leaving this issue until then, or if anyone else wishes to comment or implement.

@jonabc
Copy link
Collaborator

@jonabc jonabc commented Oct 1, 2018

@mlinksva if you want to give that regex a shot that would be great, otherwise I'll try to get to this soon.

  • LICENSES
  • THIRD-PARTY-LICENSE

It's not clear... should these be found from licensee?

@mlinksva
Copy link
Contributor Author

@mlinksva mlinksva commented Oct 1, 2018

Might appear idiosyncratic, but no and yes...confirmed:

> Licensee::ProjectFiles::LicenseFile::name_score("LICENSES")
=> 0.0
> Licensee::ProjectFiles::LicenseFile::name_score("THIRD-PARTY-LICENSE")
=> 0.6

It probably makes sense to avoid latter match in licensee, now that you mention it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants