BaseTools/PatchCheck: Support Contribution Agreement 1.1
authorMichael D Kinney <michael.d.kinney@intel.com>
Wed, 12 Jul 2017 20:11:07 +0000 (13:11 -0700)
committerMichael D Kinney <michael.d.kinney@intel.com>
Thu, 3 Aug 2017 18:01:46 +0000 (11:01 -0700)
https://bugzilla.tianocore.org/show_bug.cgi?id=628

Update PatchCheck.py to support either
"Contributed-under: TianoCore Contribution Agreement 1.0"
or "Contributed-under: TianoCore Contribution Agreement 1.1"
in the commit message.

Temporarily continue to allow the TianoCore Contribution
Agreement 1.0 agreement.

Cc: Leif Lindholm <leif.lindholm@linaro.org>
Cc: Andrew Fish <afish@apple.com>
Cc: Jordan Justen <jordan.l.justen@intel.com>
Cc: Liming Gao <liming.gao@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Michael D Kinney <michael.d.kinney@intel.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
BaseTools/Scripts/PatchCheck.py

index 7bc5736..43bfc24 100755 (executable)
@@ -75,10 +75,13 @@ class CommitMessageCheck:
             count += 1\r
 \r
     def check_contributed_under(self):\r
-        cu_msg='Contributed-under: TianoCore Contribution Agreement 1.0'\r
+        cu_msg='Contributed-under: TianoCore Contribution Agreement 1.1'\r
         if self.msg.find(cu_msg) < 0:\r
-            self.error('Missing Contributed-under! (Note: this must be ' +\r
-                       'added by the code contributor!)')\r
+            # Allow 1.0 for now while EDK II community transitions to 1.1\r
+            cu_msg='Contributed-under: TianoCore Contribution Agreement 1.0'\r
+            if self.msg.find(cu_msg) < 0:\r
+                self.error('Missing Contributed-under! (Note: this must be ' +\r
+                           'added by the code contributor!)')\r
 \r
     @staticmethod\r
     def make_signature_re(sig, re_input=False):\r