#!/usr/bin/make -f none: @echo Content-Type: text/plain @echo @echo usage make site for [re]generate site site: set -x; \ svn update; \ release=`svn log -v --limit 1 http://svn.uvw.ru/mhddfs/tags|\ tail -n2|head -n1|sed 's/-/_/g'`; \ last_version=`echo $$release \ |sed 's/[^[:digit:]]*//'`; \ tarname=mhddfs_$$last_version.tar.gz; \ if ! test -f downloads/$$tarname; then \ svn co http://svn.uvw.ru/mhddfs/tags/$$release \ mhddfs-$$last_version; \ find mhddfs-$$last_version -type d \ -name .svn -exec rm -fr '{}' +; \ tar -czvf downloads/$$tarname mhddfs-$$last_version; \ rm -fr mhddfs-$$last_version; \ svn add downloads/$$tarname; \ svn commit -m release-$$last_version downloads/$$tarname; \ fi; \ make -s dindex > downloads/index.html; \ install -m 0644 index.tmpl.html index.html; \ perl -pi -e "s/#VERSION#/$$last_version/g; \ s/#DATE#/`date +'%d %b %Y'`/g" index.html; \ svn commit -m release-$$last_version index.html dindex: @echo "" @echo "
" @echo "| File Name | " @echo "Size | " @echo "md5sum | " @echo "Date | " @echo "
|---|---|---|---|
| .. | " @echo "" @echo " | " @echo " | " @echo " |
| $$name | "; \ echo "`du -h $$file|awk '{print $$1}'` | "; \ echo "`md5sum $$file|awk '{print $$1}'` | "; \ echo "`stat -c %y $$file|sed 's/\..*//'` | "; \ echo "