Patchwork D895: check-code: allow an exception for camelcase where required

login
register
mail settings
Submitter phabricator
Date Oct. 2, 2017, 5:23 p.m.
Message ID <86b4321eba15dc7722fa06ffb8beacc7@localhost.localdomain>
Download mbox | patch
Permalink /patch/24401/
State Not Applicable
Headers show

Comments

phabricator - Oct. 2, 2017, 5:23 p.m.
This revision was automatically updated to reflect the committed changes.
Closed by commit rHGb332c01247d8: check-code: allow an exception for camelcase where required (authored by sid0, committed by ).

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D895?vs=2316&id=2337

REVISION DETAIL
  https://phab.mercurial-scm.org/D895

AFFECTED FILES
  contrib/check-code.py

CHANGE DETAILS




To: sid0, #hg-reviewers, indygreg
Cc: mercurial-devel

Patch

diff --git a/contrib/check-code.py b/contrib/check-code.py
--- a/contrib/check-code.py
+++ b/contrib/check-code.py
@@ -273,7 +273,7 @@ 
 #    (r'^\s+[^_ \n][^_. \n]+_[^_\n]+\s*=',
 #     "don't use underbars in identifiers"),
     (r'^\s+(self\.)?[A-Za-z][a-z0-9]+[A-Z]\w* = ',
-     "don't use camelcase in identifiers"),
+     "don't use camelcase in identifiers", r'#.*camelcase-required'),
     (r'^\s*(if|while|def|class|except|try)\s[^[\n]*:\s*[^\\n]#\s]+',
      "linebreak after :"),
     (r'class\s[^( \n]+:', "old-style class, use class foo(object)",