diff options
author | obrien <obrien@FreeBSD.org> | 2002-06-23 00:55:03 +0000 |
---|---|---|
committer | obrien <obrien@FreeBSD.org> | 2002-06-23 00:55:03 +0000 |
commit | 68e7c19af4119b5b78110a279f880e3912420f4d (patch) | |
tree | 8fcbd7d242a6943342e21239812420139a07863f /usr.bin | |
parent | 10013b9b848fa08fe8796c933d4afc37c3c15b15 (diff) | |
download | FreeBSD-src-68e7c19af4119b5b78110a279f880e3912420f4d.zip FreeBSD-src-68e7c19af4119b5b78110a279f880e3912420f4d.tar.gz |
Replace a perl usage with an AWK one.
Submitted by: Bob Willcox <bob@immure.com>
Diffstat (limited to 'usr.bin')
-rw-r--r-- | usr.bin/locate/locate/mklocatedb.sh | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/usr.bin/locate/locate/mklocatedb.sh b/usr.bin/locate/locate/mklocatedb.sh index f0a5434..5bb0e7a 100644 --- a/usr.bin/locate/locate/mklocatedb.sh +++ b/usr.bin/locate/locate/mklocatedb.sh @@ -76,7 +76,7 @@ if [ X"$1" = "X-presort" ]; then $code $bigrams > $filelist || exit 1 locate -d $filelist / | $bigram | $sort -nr | head -128 | - perl -ne '/^\s*[0-9]+\s(..)$/ && print $1 || exit 1' > $bigrams || exit 1 + awk '{if (/^[ ]*[0-9]+[ ]+..$/) {printf("%s",$2)} else {exit 1}}' > $bigrams || exit 1 locate -d $filelist / | $code $bigrams || exit 1 exit |