From 86ca11222a905a122773029da44223bea0171490 Mon Sep 17 00:00:00 2001 From: Greg King Date: Sun, 17 Apr 2022 14:47:19 -0400 Subject: [PATCH] Fixed and tightenned the find commands' expressions. --- .github/checks/lastline.sh | 2 +- .github/checks/spaces.sh | 2 +- .github/checks/tabs.sh | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/checks/lastline.sh b/.github/checks/lastline.sh index 464f1774a..797b6acfd 100755 --- a/.github/checks/lastline.sh +++ b/.github/checks/lastline.sh @@ -8,7 +8,7 @@ cd $SCRIPT_PATH/../../ nl=' ' nl=$'\n' -FILES=`find $CHECK_PATH -type f \( \( -name \*.inc -a \! -name Makefile.inc \) -o -name \*.cfg -o -name \*.c -o -name \*.s -o -name \*.h -o -name \*.asm -o -name \*.sgml \) -print | while read f; do +FILES=`find $CHECK_PATH -type f \( -name \*.inc -o -name Makefile -o -name \*.cfg -o -name \*.\[chs\] -o -name \*.asm -o -name \*.sgml \) -print | while read f; do t=$(tail -c2 $f; printf x); r1="${nl}$"; [[ ${t%x} =~ $r1 ]] || echo "$f" done` diff --git a/.github/checks/spaces.sh b/.github/checks/spaces.sh index 71bdd877f..02a03ff58 100755 --- a/.github/checks/spaces.sh +++ b/.github/checks/spaces.sh @@ -5,7 +5,7 @@ CHECK_PATH=. cd $SCRIPT_PATH/../../ -FILES=`find $CHECK_PATH -type f \( \( -name \*.inc -a \! -name Makefile.inc \) -o -name \*.cfg -o -name \*.c -o -name \*.s -o -name \*.h -o -name \*.asm -o -name \*.sgml \) -print | xargs grep -l ' $' | grep -v "libwrk/" | grep -v "testwrk/"` +FILES=`find $CHECK_PATH -type f \( -name \*.inc -o -name Makefile -o -name \*.cfg -o -name \*.\[chs\] -o -name \*.asm -o -name \*.sgml \) -print | xargs grep -l ' $' | grep -v "libwrk/" | grep -v "testwrk/"` cd $OLDCWD diff --git a/.github/checks/tabs.sh b/.github/checks/tabs.sh index db2b61eac..3823eb370 100755 --- a/.github/checks/tabs.sh +++ b/.github/checks/tabs.sh @@ -5,7 +5,7 @@ CHECK_PATH=. cd $SCRIPT_PATH/../../ -FILES=`find $CHECK_PATH -type f \( \( -name \*.inc -a \! -name Makefile.inc \) -o -name \*.cfg -o -name \*.c -o -name \*.s -o -name \*.h -o -name \*.asm -o -name \*.sgml \) -print | xargs grep -l $'\t' | grep -v "libwrk/" | grep -v "testwrk/"` +FILES=`find $CHECK_PATH -type f \( \( -name \*.inc -a \! -name Makefile.inc \) -o -name \*.cfg -o -name \*.\[chs\] -o -name \*.asm -o -name \*.sgml \) -print | xargs grep -l $'\t' | grep -v "libwrk/" | grep -v "testwrk/"` cd $OLDCWD