-sicnt=`grep 'ions per' OUTCAR | awk '{ print $5 }'`
-ccnt=`grep 'ions per' OUTCAR | awk '{ print $6 }'`
+if [ "$1" = "renew" ]; then
+ rm -rf video$app
+fi
+
+if [ -d video$app ]; then
+ echo "skipping $app ... (use $0 renew to force rebuild)"
+ continue
+fi
+
+mkdir -p video$app
+
+sicnt=`grep 'ions per' $i | awk '{ print $5 }'`
+ccnt=`grep 'ions per' $i | awk '{ print $6 }'`