Patchwork D6789: check-code: allow command substitution with $(command)

login
register
mail settings
Submitter phabricator
Date Sept. 7, 2019, 4:54 p.m.
Message ID <b3a0ccfb2562fd0119488f5ca486e8de@localhost.localdomain>
Download mbox | patch
Permalink /patch/41544/
State Not Applicable
Headers show

Comments

phabricator - Sept. 7, 2019, 4:54 p.m.
Closed by commit rHG4257c33e24b7: check-code: allow command substitution with $(command) (authored by martinvonz).
This revision was automatically updated to reflect the committed changes.

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D6789?vs=16394&id=16433

CHANGES SINCE LAST ACTION
  https://phab.mercurial-scm.org/D6789/new/

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

AFFECTED FILES
  contrib/check-code.py

CHANGE DETAILS




To: martinvonz, #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
@@ -116,7 +116,6 @@ 
     (r'\bls\b.*-\w*R', "don't use 'ls -R', use 'find'"),
     (r'printf.*[^\\]\\([1-9]|0\d)', r"don't use 'printf \NNN', use Python"),
     (r'printf.*[^\\]\\x', "don't use printf \\x, use Python"),
-    (r'\$\(.*\)', "don't use $(expr), use `expr`"),
     (r'rm -rf \*', "don't use naked rm -rf, target a directory"),
     (r'\[[^\]]+==', '[ foo == bar ] is a bashism, use [ foo = bar ] instead'),
     (r'(^|\|\s*)grep (-\w\s+)*[^|]*[(|]\w',