Commit b52a4b72 by Richard Stallman

(egrep and sed loop): Don't print messages about files that need no change.

From-SVN: r3200
parent d0691cfb
...@@ -230,7 +230,6 @@ while [ $# != 0 ]; do ...@@ -230,7 +230,6 @@ while [ $# != 0 ]; do
# won't be able to handle it. # won't be able to handle it.
# rms: I removed `|#[el].*if.*[^/ ]' because it made egrep fail. # rms: I removed `|#[el].*if.*[^/ ]' because it made egrep fail.
if egrep '//|[ _]_IO|CTRL|#define.NULL|#[el]*if.*([0-9]|sparc|vax|sun|pyr)' $file > /dev/null; then if egrep '//|[ _]_IO|CTRL|#define.NULL|#[el]*if.*([0-9]|sparc|vax|sun|pyr)' $file > /dev/null; then
echo Fixing $file
if [ -r $file ]; then if [ -r $file ]; then
cp $file $2/$file >/dev/null 2>&1 \ cp $file $2/$file >/dev/null 2>&1 \
|| echo "Can't copy $file" || echo "Can't copy $file"
...@@ -270,6 +269,8 @@ while [ $# != 0 ]; do ...@@ -270,6 +269,8 @@ while [ $# != 0 ]; do
mv $2/$file.sed $2/$file mv $2/$file.sed $2/$file
if cmp $file $2/$file >/dev/null 2>&1; then if cmp $file $2/$file >/dev/null 2>&1; then
rm $2/$file rm $2/$file
else
echo Fixed $file
fi fi
fi fi
fi fi
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment