Make linkifying "bug N" case-insensitive.
authorBenjamin Smedberg <benjamin@smedbergs.us>
Tue, 31 Jan 2012 12:26:29 -0500
changeset 33 4ca7bd8e545c
parent 32 11f31b62f654
child 34 58a50f7635c2
push id28
push userbsmedberg@mozilla.com
push date2012-01-31 17:26 +0000
Make linkifying "bug N" case-insensitive.
weeklyupdates/post.py
--- a/weeklyupdates/post.py
+++ b/weeklyupdates/post.py
@@ -1,16 +1,16 @@
 import datetime
 from genshi.filters import HTMLSanitizer
 from genshi.input import HTML, ParseError
 import markdown2
 import re
 
 link_patterns = (
-    (re.compile(r'(https?://.*?(?=[\s\]\)\|]))'), r'\1'),
+    (re.compile(r'(https?://.*?(?=[\s\]\)\|]))', re.I), r'\1'),
     (re.compile(r'bug[\s:#]+(\d{3,7})\b'), r'https://bugzilla.mozilla.org/show_bug.cgi?id=\1'),
 )
 
 md = markdown2.Markdown(html4tags=True, tab_width=2,
                         extras=['link-patterns',
                                 'cuddled-lists'],
                         link_patterns=link_patterns)