Mercurial > hg-stable
changeset 29569:3d52e7c78a6b
check-code: move fixing up regexp into main procedure
This patch makes an extra check pattern to be prepared by
"_preparepats()" as similarly as existing patterns, if it is added to
"checks" array before invocation of "main()" in check-code.py.
This is a part of preparation for adding check-code.py extra checks by
another python script in subsequent patch.
This is also useful for SkeletonExtensionPlan.
https://www.mercurial-scm.org/wiki/SkeletonExtensionPlan
author | FUJIWARA Katsunori <foozy@lares.dti.ne.jp> |
---|---|
date | Fri, 20 May 2016 09:47:35 +0900 |
parents | 7825f6154a65 |
children | cbd240188e4e |
files | contrib/check-code.py |
diffstat | 1 files changed, 2 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/contrib/check-code.py Fri May 20 09:47:35 2016 +0900 +++ b/contrib/check-code.py Fri May 20 09:47:35 2016 +0900 @@ -474,7 +474,6 @@ filters = c[3] for i, flt in enumerate(filters): filters[i] = re.compile(flt[0]), flt[1] -_preparepats() class norepeatlogger(object): def __init__(self): @@ -644,6 +643,8 @@ else: check = args + _preparepats() + ret = 0 for f in check: if not checkfile(f, maxerr=options.per_file, warnings=options.warnings,