https://www.gnu.org/licenses/identify-licenses-clearly.html:
"I did not know how developers would respond to this innovation, so I
decided to give each developer a choice about allowing future
versions. This meant developers could release a program under GNU GPL
version 1 only, or release it under GPL version 1 or any later
version. The way developers state their choice is in the license notice
that goes at the start of each source file. That's where the GPL says
the decision is stated."
https://spdx.org/using-spdx#identifiers:
"The SPDX Work-group proposes to use SPDX license identifiers to
indicate the license at the file level."
Rather than querying the local filesystem, we can use the Github API to
resolve folder contents and the individual files within.
This isn't going to be performant - requests are not made in parallel -
and there is absolutely no error handling.
Some packaging systems allow you to make these distinctions. For
example, Python supports "or later" Trove classifiers [1] and npm
allows SPDX license expression syntax v2.0 [2] (and SPDX expressions
support '+', e.g. 'GPL-2.0+' [3]).
The point of this paragraph is that such an entry is metadata which
may not be sufficiently binding [4], while including the full license
text is much more likely to be legally binding. By removing the FUD
about "cannot distinguish between GPL-2.0 and GPL-2.0+", we can focus
on the point that actually matters.
[1]: https://pypi.python.org/pypi?%3Aaction=list_classifiers
> License :: OSI Approved :: GNU General Public License v2 (GPLv2)
> License :: OSI Approved :: GNU General Public License v2 or later (GPLv2+)
[2]: https://docs.npmjs.com/files/package.json#license
> If your package is licensed under multiple common licenses, use
> an SPDX license expression syntax version 2.0 string...
[3]: https://spdx.org/sites/cpstandard/files/pages/files/spdx-2.0.pdf#page=82
> An SPDX License List Short Form Identifier with a unary "+"
> operator suffix to represent the current version of the license
> or any later version. For example: GPL-2.0+
[4]: https://github.com/benbalter/licensee/issues/4
What's legally sufficient to constitute a grant of an open source
software license?
`license_file.rb` was edited since the link was first made, so the range pointed to the wrong part of the file. With this change, the range once again cover the `FILENAME_REGEXES` hash contents.