view makeBooke.sh @ 370:ecc62b487e57 build-default-165

Some empty "" chords may be causing trouble with Jenkins. Jenkins builds are stalling when generating PDFs for some morris tunes. I suspect the problem may be an empty chord "" and abc2abc's attempt to transpose it. I've been meaning to remove the chords from the horn output, because abc2abc transposes them too, which renders them not terribly useful. So get on and do it. Also remove "" from the morris tunes where it occurs.
author Jim Hague <jim.hague@acm.org>
date Wed, 28 Aug 2013 14:57:11 +0100
parents 2a7d03d6a89f
children 0206ab9fd6ba
line wrap: on
line source

#!/bin/bash
#
# Build the Booke. Move subfiles into place and build the Booke into a PDF.
#
# The Booke tune content and all EPS and PDF tune graphics must be
# present already. Run makeGraphics.sh first and then
# makeBookeTunePages.sh.
#

if [ $# != 2 ]; then
    echo "Usage: makeBooke.sh <book dir name> <A4|A5>"
    exit 1
fi

dir=`pwd`

booke=$dir/$1
papersize=$2
builddir=$dir/build
booketex=$dir/dottes.tex
bookepdf=$builddir/dottes.pdf

mkdir -p $builddir

cp dottes.tex $builddir
cp buildno.txt $builddir
cp buzzard.pdf $builddir
for item in title subtitle instrument
do
    rm -f $builddir/$item.txt
    if [ -r $booke/$item.txt ]; then
        cp $booke/$item.txt $builddir
    else
        touch $builddir/$item.txt
    fi
done
for item in intro
do
    rm -f $builddir/$item.tex
    if [ -r $booke/$item.txt ]; then
        txt2tags --no-headers --target=tex --outfile=$builddir/$item.tex $booke/$item.txt
    else
        touch $builddir/$item.tex
    fi
done

for filename in $dir/*.${papersize}.tex
do
    name=`basename $filename .${papersize}.tex`
    cp $filename $builddir/$name.tex
done

cd $builddir

xelatex $booketex
xelatex $booketex
xelatex $booketex

mv $bookepdf $dir/$1-${papersize}.pdf

cd $dir