1 2 3 4 5 6 7 8 9 10 11 12 13
#! /bin/sh if [ ! -f .version ] then echo 0 > .version fi cycle=`cat .version` cycle=`expr $cycle + 1` if [ $cycle -gt 99 ] then cycle=0 fi echo $cycle > .version