[devscripts] 01/01: licensecheck: tweaked to parse Artistic 2.0 license file
Dominique Dumont
dod at debian.org
Sun Dec 20 19:18:14 UTC 2015
On Sunday 20 December 2015 23:48:40 Osamu Aoki wrote:
> Since the whole "(?:^|(?:This is ........... terms of )?)" is followed
> with "?" making it completely optional, I do not see the reason to have
> "^" and the other matching.
You're right. I made a mistake, Sorry about that. The extra '?' must be
removed.
> Why not simply
>
> > + if ($licensetext =~ /[Tt]he Artistic License ([v\d.]+)/) {
>
> If you require one of the matching, the whole "(?:^|(?:This is
> ........... terms of )?)" should not be followed by "?".
>
> I am confused with this rule.
The idea is to avoid assigning Artistic license to a file containing a string
like "I do not want the artistic license v2.0".
The rules is supposed to match when either:
- a license grant is found. i.e something like "this is free software,
licensed under the artistic license v2.0"
- the text *begins* with "The Artistic license v2.0" which is (hopefully) the
actual artistic license v2.0 text.
I'll fix the regexp to follow these rules.
Thanks for the heads-up.
All the best
--
https://github.com/dod38fr/ -o- http://search.cpan.org/~ddumont/
http://ddumont.wordpress.com/ -o- irc: dod at irc.debian.org
More information about the devscripts-devel
mailing list