Skip to content

Commit

Permalink
unified validation script; minor fixes in ldf2* scripts
Browse files Browse the repository at this point in the history
git-svn-id: https://slps.svn.sourceforge.net/svnroot/slps@186 ab42f6e0-554d-0410-b580-99e487e6eeb2
  • Loading branch information
grammarware committed Aug 19, 2008
1 parent 784f4bd commit a0fa482
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 22 deletions.
19 changes: 0 additions & 19 deletions shared/tools/checkbgf

This file was deleted.

23 changes: 23 additions & 0 deletions shared/tools/checkxml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
#!/bin/sh

# Get our hands on basedir
LOCAL1=${PWD}
cd `dirname $0`
cd ../..
SLPS=${PWD}
cd ${LOCAL1}

if [ $# -ne 2 ]; then
echo "Usage: checkxml <format> <xml-input>"
exit 1
elif [ ! -r $2 ]; then
echo "Oops: $2 not found or not readable."
exit 1
elif [ ! -r ${SLPS}/shared/xsd/$1.xsd ]; then
echo "Oops: schema for $1 not found or not readable."
exit 1
elif [ "$1" == "ldf" ]; then
java -jar ${SLPS}/download/msv/msv.jar ${SLPS}/shared/xsd/$1.xsd $2
else
xmllint --noout --schema ${SLPS}/shared/xsd/$1.xsd $2
fi
3 changes: 1 addition & 2 deletions shared/tools/ldf2html
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,5 @@ elif [ ! -r $1 ]; then
echo "Oops: $1 not found or not readable."
exit 1
else
rm -f $2
xsltproc ${SLPS}/shared/xsl/ldf2xhtml.xslt $1 | python ${SLPS}/topics/extraction/ldf2pdf/closemeta.py > $2
xsltproc ${SLPS}/shared/xsl/ldf2xhtml.xslt $1 | python ${SLPS}/topics/extraction/ldf2pdf/closemeta.py > $2
fi
1 change: 0 additions & 1 deletion shared/tools/ldf2pdf
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ elif [ ! -r $1 ]; then
echo "Oops: $1 not found or not readable."
exit 1
else
rm -f $2
sh ${SLPS}/shared/tools/ldf2html $1 html.tmp
xsltproc ${SLPS}/shared/xsl/xhtml2fo.xslt html.tmp > fo.tmp
${SLPS}/download/fop/fop -q fo.tmp $2
Expand Down

0 comments on commit a0fa482

Please sign in to comment.