|
@@ -7,13 +7,21 @@ else
|
|
echo Checking $1 ...
|
|
echo Checking $1 ...
|
|
pushd $1 >/dev/null
|
|
pushd $1 >/dev/null
|
|
fi
|
|
fi
|
|
-if [ ! -f series ]
|
|
|
|
|
|
+if [ -f series-test ]
|
|
then
|
|
then
|
|
- echo no series file found
|
|
|
|
|
|
+ SERIES=series-test
|
|
|
|
+ FILES=`cat series-test`
|
|
|
|
+else
|
|
|
|
+ SERIES=series
|
|
|
|
+ FILE=*
|
|
|
|
+fi
|
|
|
|
+if [ ! -f $SERIES ]
|
|
|
|
+then
|
|
|
|
+ echo no $SERIES file found
|
|
popd >/dev/null
|
|
popd >/dev/null
|
|
exit 1
|
|
exit 1
|
|
fi
|
|
fi
|
|
-for i in *
|
|
|
|
|
|
+for i in $FILES
|
|
do
|
|
do
|
|
if [ "$i" != "series" -a "$i" != "status" ]
|
|
if [ "$i" != "series" -a "$i" != "status" ]
|
|
then
|
|
then
|
|
@@ -24,11 +32,11 @@ do
|
|
ERRORS=`expr $ERRORS + 1`
|
|
ERRORS=`expr $ERRORS + 1`
|
|
fi
|
|
fi
|
|
j=`echo $i | sed -e 's@\.@\\\.@g'`
|
|
j=`echo $i | sed -e 's@\.@\\\.@g'`
|
|
- COUNT=`grep ^$j$ series | wc | sed -e 's@^\s*@@g' -e 's@ .*$@@g'`
|
|
|
|
|
|
+ COUNT=`grep ^$j$ $SERIES | wc | sed -e 's@^\s*@@g' -e 's@ .*$@@g'`
|
|
if [ "$COUNT" != "1" ]
|
|
if [ "$COUNT" != "1" ]
|
|
then
|
|
then
|
|
ERRORS=`expr $ERRORS + 1`
|
|
ERRORS=`expr $ERRORS + 1`
|
|
- echo $i appears $COUNT times in series
|
|
|
|
|
|
+ echo $i appears $COUNT times in $SERIES
|
|
fi
|
|
fi
|
|
# NUM=3
|
|
# NUM=3
|
|
NUM=`grep -n '^diff' $i | head -1 | sed -e 's@\:.*$@@'`
|
|
NUM=`grep -n '^diff' $i | head -1 | sed -e 's@\:.*$@@'`
|
|
@@ -62,11 +70,11 @@ do
|
|
fi
|
|
fi
|
|
fi
|
|
fi
|
|
done
|
|
done
|
|
-for i in `cat series`
|
|
|
|
|
|
+for i in `cat $SERIES`
|
|
do
|
|
do
|
|
if [ ! -f $i ]
|
|
if [ ! -f $i ]
|
|
then
|
|
then
|
|
- echo File $i in series does not exist.
|
|
|
|
|
|
+ echo File $i in $SERIES does not exist.
|
|
ERRORS=`expr $ERRORS + 1`
|
|
ERRORS=`expr $ERRORS + 1`
|
|
echo $i
|
|
echo $i
|
|
fi
|
|
fi
|