##// END OF EJS Templates
check-code: two more rules...
Matt Mackall -
r10451:63a9bfad default
parent child Browse files
Show More
@@ -10,7 +10,8 b''
10 import sys, re, glob
10 import sys, re, glob
11
11
12 def repquote(m):
12 def repquote(m):
13 t = re.sub(r"\S", "x", m.group(2))
13 t = re.sub(r"\w", "x", m.group(2))
14 t = re.sub(r"[^\sx]", "o", t)
14 return m.group(1) + t + m.group(1)
15 return m.group(1) + t + m.group(1)
15
16
16 def repcomment(m):
17 def repcomment(m):
@@ -88,6 +89,8 b' pypats = ['
88 (r'[^>< ](\+=|-=|!=|<>|<=|>=|<<=|>>=)\s', "missing whitespace around operator"),
89 (r'[^>< ](\+=|-=|!=|<>|<=|>=|<<=|>>=)\s', "missing whitespace around operator"),
89 (r'\s(\+=|-=|!=|<>|<=|>=|<<=|>>=)\S', "missing whitespace around operator"),
90 (r'\s(\+=|-=|!=|<>|<=|>=|<<=|>>=)\S', "missing whitespace around operator"),
90 (r'[^+=*!<>&| -](\s=|=\s)[^= ]', "wrong whitespace around ="),
91 (r'[^+=*!<>&| -](\s=|=\s)[^= ]', "wrong whitespace around ="),
92 (r'raise Exception', "don't raise generic exceptions"),
93 (r'ui\.(status|progress|write|note)\([\'\"]x', "unwrapped ui message"),
91 ]
94 ]
92
95
93 pyfilters = [
96 pyfilters = [
General Comments 0
You need to be logged in to leave comments. Login now