aboutsummaryrefslogtreecommitdiffstats
path: root/tools/check-copyright.sh
diff options
context:
space:
mode:
authorAndrew Donnellan <ajd@linux.ibm.com>2025-12-10 13:43:04 +1100
committerAleksandr Nogikh <nogikh@google.com>2025-12-10 05:39:31 +0000
commit5b5f646079e8abe6d9b1f550aaf0e837b2f5ea13 (patch)
tree0fc36fe75b4fc936f26624daab539bc60c5f4812 /tools/check-copyright.sh
parent6309de2073070b3516f0e786221f116238423d31 (diff)
all: replace egrep with grep -E
The egrep command has been deprecated in GNU Grep since 2007, and nowadays using egrep rather than grep -E will print a warning to the user, which is very annoying. Replace all usages of egrep with grep -E. Signed-off-by: Andrew Donnellan <ajd@linux.ibm.com>
Diffstat (limited to 'tools/check-copyright.sh')
-rwxr-xr-xtools/check-copyright.sh6
1 files changed, 3 insertions, 3 deletions
diff --git a/tools/check-copyright.sh b/tools/check-copyright.sh
index fe88c5eaf..ba28df438 100755
--- a/tools/check-copyright.sh
+++ b/tools/check-copyright.sh
@@ -6,12 +6,12 @@ FILES=0
FAILED=""
for F in $(find . -name "*.go" -o -name "*.sh" -o -name "*.cpp" -o -name "*.cc" -o -name "*.h" \
-o -name "*.S" -o -name "*.py" -o -name "*.yml" -o -name "*.yaml" -o -name "*.fbs" \
- -o \( -path "./sys/*/*.txt" \) | egrep -v "/_include/|/gen/|/testdata/"); do
+ -o \( -path "./sys/*/*.txt" \) | grep -E -v "/_include/|/gen/|/testdata/"); do
((FILES+=1))
- cat $F | tr '\n' '_' | egrep "(//|#) Copyright 20[0-9]{2}(/20[0-9]{2})? syzkaller project authors\. All rights reserved\._(//|#) Use of this source code is governed by Apache 2 LICENSE that can be found in the LICENSE file\." >/dev/null
+ cat $F | tr '\n' '_' | grep -E "(//|#) Copyright 20[0-9]{2}(/20[0-9]{2})? syzkaller project authors\. All rights reserved\._(//|#) Use of this source code is governed by Apache 2 LICENSE that can be found in the LICENSE file\." >/dev/null
if [ $? -eq 0 ]; then continue; fi
# Ignore auto-generated files.
- egrep "^(//|#) Code generated .* DO NOT EDIT\\.|(WARNING: This file is machine generated)|automatically generated by the FlatBuffers compiler" $F >/dev/null
+ grep -E "^(//|#) Code generated .* DO NOT EDIT\\.|(WARNING: This file is machine generated)|automatically generated by the FlatBuffers compiler" $F >/dev/null
if [ $? -eq 0 ]; then continue; fi
# Ignore untracked files.
git ls-files --error-unmatch $F >/dev/null 2>&1