[licensecheck] 101/112: Fix tighten detection of mit_new license (was misdetecting other MIT flavors).

Jonas Smedegaard dr at jones.dk
Fri Nov 25 22:03:00 UTC 2016


This is an automated email from the git hooks/post-receive script.

js pushed a commit to branch master
in repository licensecheck.

commit 940389ab3700dcbffb758b4f122c8d6fe6c7ddf7
Author: Jonas Smedegaard <dr at jones.dk>
Date:   Fri Nov 25 21:11:04 2016 +0100

    Fix tighten detection of mit_new license (was misdetecting other MIT flavors).
---
 lib/Regexp/Pattern/License.pm       |  3 +--
 lib/Regexp/Pattern/License/Parts.pm | 12 ++++++++++++
 2 files changed, 13 insertions(+), 2 deletions(-)

diff --git a/lib/Regexp/Pattern/License.pm b/lib/Regexp/Pattern/License.pm
index 9303cdc..07e46ae 100644
--- a/lib/Regexp/Pattern/License.pm
+++ b/lib/Regexp/Pattern/License.pm
@@ -461,8 +461,7 @@ our %RE = (
 		caption                  => 'MIT (Expat)',
 		'caption.alt.org.debian' => 'MIT/X11 (BSD like)',
 		tags                     => ['mit'],
-		pat =>
-			qr/$P{permission_person_sw_doc}, $P{permission_use_deal_sw}|opensource\.org:?\/licenses\/mit-license\.php/,
+		pat => qr/$P{right_mod_sublic}\b[^.]+\s+$P{note_cpyr_perm_subst}/,
 	},
 	mit_new_materials => {
 		'name.alt.org.debian' => 'MIT~Khronos',
diff --git a/lib/Regexp/Pattern/License/Parts.pm b/lib/Regexp/Pattern/License/Parts.pm
index 48f5603..9941fe9 100644
--- a/lib/Regexp/Pattern/License/Parts.pm
+++ b/lib/Regexp/Pattern/License/Parts.pm
@@ -292,6 +292,12 @@ our %RE = (
 		pat =>
 			qr/provided that the above copyright notice and this permission notice appear in all copies/,
 	},
+	note_cpyr_perm_subst => {
+		caption => 'notices (copyright, permission, substantial portions)',
+		tags    => ['clause'],
+		pat =>
+			qr/The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software/,
+	},
 	note_invar => {
 		caption => 'notice (invariable)',
 		tags    => ['clause'],
@@ -350,6 +356,12 @@ our %RE = (
 		pat =>
 			qr/$granted, $no_charge, $to_person of $sw_docfiles \(the "?Software"?\)/,
 	},
+	right_mod_sublic => {
+		caption => 'rights (modify, sublicense)',
+		tags    => ['clause'],
+		pat =>
+			qr/to use, copy, modify, merge, publish, distribute, sublicense, and\/or sell copies of the Software/,
+	},
 	use_sw_doc_any => {
 		caption => 'usage (software and documentation, any purpose)',
 		tags    => ['clause'],

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-perl/packages/licensecheck.git



More information about the Pkg-perl-cvs-commits mailing list