update sqg

This commit is contained in:
chess.griffin 2013-12-09 02:13:44 +00:00
parent 7909639bb0
commit 885076e024

View File

@ -120,12 +120,19 @@ parse_queuefile_requires () {
} }
build_queuefile () { build_queuefile () {
QUEUEFILE=$QUEUEDIR/$PRGNAM.sqf OLDFILE=$QUEUEDIR/$PRGNAM.sqf
QUEUEFILE=$QUEUEDIR/$PRGNAM.sqf.tmp
CATFILE=$QUEUEDIR/tmp.sqf
touch $QUEUEFILE touch $QUEUEFILE
echo "$PRGNAM" > $QUEUEFILE echo "$PRGNAM" > $QUEUEFILE
parse_queuefile_requires $PRGNAM parse_queuefile_requires $PRGNAM
tac $QUEUEFILE > $QUEUEDIR/tmp.sqf tac $QUEUEFILE > $CATFILE
mv $QUEUEDIR/tmp.sqf $QUEUEFILE if cmp -s "$CATFILE" "$OLDFILE"; then
rm $QUEUEFILE $CATFILE
else
mv $CATFILE $OLDFILE
rm $QUEUEFILE
fi
} }
main_loop () { main_loop () {