changeset 32696:0c09afdf5704

check-code: ban grep's context flags (-A/-B/-C) since they're not on Solaris
author Danek Duvall <danek.duvall@oracle.com>
date Tue, 06 Jun 2017 08:58:27 -0700
parents 0841382d114a
children 19b9fc40cc51
files contrib/check-code.py
diffstat 1 files changed, 1 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/contrib/check-code.py	Tue Jun 06 08:52:51 2017 +0200
+++ b/contrib/check-code.py	Tue Jun 06 08:58:27 2017 -0700
@@ -145,6 +145,7 @@
     (r'\bsed\b.*[^\\]\\n', "don't use 'sed ... \\n', use a \\ and a newline"),
     (r'env.*-u', "don't use 'env -u VAR', use 'unset VAR'"),
     (r'cp.* -r ', "don't use 'cp -r', use 'cp -R'"),
+    (r'grep.* -[ABC] ', "don't use grep's context flags"),
   ],
   # warnings
   [