#!/bin/sh # $Id$ # read the CTAN catalogue and update the TPM files where possible Master=`cd \`dirname $0\`/../../Master && /bin/pwd` cd $Master || exit 1 test $# -eq 0 && set - `find texmf-dist/tpm -name "*.tpm"` for i in "$@"; do echo Try to update $i p4 edit $i N=`basename $i .tpm` L=`echo $N | sed 's/\(.\).*/\1/'` wget -q -O x.xml \ http://cvs.sarovar.org/cgi-bin/cvsweb.cgi/~checkout~/texcatalogue/entries/$L/$N.xml?cvsroot=texcatalogue grep -q "" > x.xml xmllint --dropdtd x.xml > /tmp/$N.xml xsltproc \ -o $N.tpm \ --stringparam sarovar /tmp/$N.xml \ --stringparam authors `pwd`/texmf-doc/doc/english/catalogue/authors.xml \ `pwd`/Tools/tpmfromcat.xsl $i xmllint --format $N.tpm > $i rm x.xml /tmp/$N.xml $N.tpm done p4 revert -a