Mercurial > public > mercurial-scm > hg-stable
diff contrib/check-code.py @ 34642:a679aa582d8d
check-code: forbid platform.system()
See the previous patches for the reason.
Differential Revision: https://phab.mercurial-scm.org/D1021
author | Jun Wu <quark@fb.com> |
---|---|
date | Wed, 11 Oct 2017 17:42:57 -0700 |
parents | 3e4b7861c1c5 |
children | 4889b84b15f2 |
line wrap: on
line diff
--- a/contrib/check-code.py Wed Oct 11 17:42:35 2017 -0700 +++ b/contrib/check-code.py Wed Oct 11 17:42:57 2017 -0700 @@ -362,6 +362,7 @@ (r'\.next\(\)', "don't use .next(), use next(...)"), (r'([a-z]*).revision\(\1\.node\(', "don't convert rev to node before passing to revision(nodeorrev)"), + (r'platform\.system\(\)', "don't use platform.system(), use pycompat"), # rules depending on implementation of repquote() (r' x+[xpqo%APM][\'"]\n\s+[\'"]x',