[yocto] [patchwork][PATCH 2/2] patchwork.bin.parsemail: Improve pull-request regex

Jose Lamego jose.a.lamego at linux.intel.com
Thu Nov 24 07:27:39 PST 2016


Some patch messages containinig pull-request information
are being skipped due to formatting variations.

This change improves the pull-request search to include those
small variants.

Signed-off-by: Jose Lamego <jose.a.lamego at linux.intel.com>
---
 patchwork/bin/parsemail.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/patchwork/bin/parsemail.py b/patchwork/bin/parsemail.py
index c10bed5..476118d 100755
--- a/patchwork/bin/parsemail.py
+++ b/patchwork/bin/parsemail.py
@@ -195,8 +195,8 @@ def mail_headers(mail):
 
 def find_pull_request(content):
     git_re = re.compile(r'^The following changes since commit.*' +
-                        r'^are available in the git repository at:\n'
-                        r'^\s*([\S]+://[^\n]+)$',
+                        r'^are available in the git repository at:.*'+
+                        r'^\s*([\S]+://[^\n]+)[$]*',
                         re.DOTALL | re.MULTILINE)
     match = git_re.search(content)
     if match:
-- 
1.9.1




More information about the yocto mailing list