summaryrefslogtreecommitdiff
path: root/tests/ere.awk
diff options
context:
space:
mode:
authorJim Meyering <meyering@redhat.com>2010-04-08 18:39:24 +0200
committerJim Meyering <meyering@redhat.com>2010-04-08 19:29:42 +0200
commit699bcc4bd8166abb6ee26a37d9e1189817741277 (patch)
treeb57f4c9bc3bf24c6b565f78966dc20ff98a4c36a /tests/ere.awk
parente4f69c178ee9e68ecdbd743de669ec8c1388e40f (diff)
downloadgrep-699bcc4bd8166abb6ee26a37d9e1189817741277.tar.gz
convert all TABs to equivalent spaces in indentation
Using this file, cat > leading-blank.exempt <<\EOF (?:^|\/)ChangeLog[^/]*$ (?:^|\/)(?:GNU)?[Mm]akefile[^/]*$ \.(?:am|mk)$ EOF run this command to convert all non-conforming leading white space to be all spaces: git ls-files \ | pcregrep -vf leading-blank.exempt \ | xargs pcregrep -l '^ *\t' \ | xargs perl -MText::Tabs -ni -le \ '$m=/^( *\t[ \t]*)(.*)/; print $m ? expand($1) . $2 : $_'
Diffstat (limited to 'tests/ere.awk')
-rw-r--r--tests/ere.awk20
1 files changed, 10 insertions, 10 deletions
diff --git a/tests/ere.awk b/tests/ere.awk
index 9a886bf5..90898a0b 100644
--- a/tests/ere.awk
+++ b/tests/ere.awk
@@ -5,21 +5,21 @@
# notice and this notice are preserved.
BEGIN {
- FS="@";
- n = 0;
- printf ("# Generated Spencer ERE Test\n");
- printf ("failures=0\n");
+ FS="@";
+ n = 0;
+ printf ("# Generated Spencer ERE Test\n");
+ printf ("failures=0\n");
}
$0 ~ /^#/ { next; }
NF == 3 {
# printf ("status=$(echo '%s' | { ${GREP} -E -e '%s' > /dev/null 2>&1; echo $?; cat >/dev/null; })\n",$3, $2);
- printf ("status=$(echo '%s' | { ${GREP} -E -e '%s' > /dev/null 2>&1; echo $?; })\n",$3, $2);
- printf ("if test $status -ne %s ; then\n", $1);
- printf ("\techo Spencer ere test \\#%d failed\n", ++n);
- printf ("\tfailures=1\n");
- printf ("fi\n");
+ printf ("status=$(echo '%s' | { ${GREP} -E -e '%s' > /dev/null 2>&1; echo $?; })\n",$3, $2);
+ printf ("if test $status -ne %s ; then\n", $1);
+ printf ("\techo Spencer ere test \\#%d failed\n", ++n);
+ printf ("\tfailures=1\n");
+ printf ("fi\n");
}
NF == 4 {
@@ -32,7 +32,7 @@ NF == 4 {
NF == 5 {
# don't alarm the user for now
- next;
+ next;
}
END { printf ("exit $failures\n"); }