ref: 6c6f09d989e5db7242365e6844c67b618192f996
dir: /bin/nightlyiso.rc/
#!/bin/rc rfork en flagfmt='f:force' eval `{aux/getflags $*} home=/usr/build cd $home/code/plan9front git/pull prev=`{cat prev} head=`{git/query HEAD} rev=`{git/log -s | wc -l} release=9front-$rev log=$home/www/9front/^$release^.log res=$home/www/9front/$rev.status echo release $release if(~ $prev $head && ~ $force '') exit buildisos.rc >$log >[2=1] date >>$log if(~ `{ls $home/www/9front/*gz | grep $rev | wc -l} 6){ echo pass >$res echo $rev >$home/www/9front/latest } if not echo fail >$res echo $head >>$res echo $head >prev #garbage collection latest=`{cat $home/www/9front/latest} for(i in `{ls $home/www/9front | grep -v $latest | grep '\.(iso|gz|img|qcow2)$'}) rm $i