|
@ -459,16 +459,16 @@ fi |
|
|
|
|
|
|
|
|
# Shortcut to include bbl |
|
|
# Shortcut to include bbl |
|
|
if test "$bbl" = 1; then |
|
|
if test "$bbl" = 1; then |
|
|
bblexpand=("--expand-bbl "$mainbase".bbl") |
|
|
|
|
|
|
|
|
bblexpand=("--expand-bbl" "$mainbase.bbl") |
|
|
else |
|
|
else |
|
|
bblexpand=("") |
|
|
|
|
|
|
|
|
bblexpand=() |
|
|
fi |
|
|
fi |
|
|
|
|
|
|
|
|
# Create flattened documents and keep for debugging |
|
|
# Create flattened documents and keep for debugging |
|
|
if test "$flatten" = 1; then |
|
|
if test "$flatten" = 1; then |
|
|
if [ "$bbl" = 1 ]; then |
|
|
if [ "$bbl" = 1 ]; then |
|
|
if [ ! -f "old/"$maindir$mainbase".bbl" ]; then |
|
|
|
|
|
verbose "Attempting to regenerate missing old/"$maindir$mainbase".bbl" |
|
|
|
|
|
|
|
|
if [ ! -f "old/$maindir$mainbase.bbl" ]; then |
|
|
|
|
|
verbose "Attempting to regenerate missing old/$maindir$mainbase.bbl" |
|
|
( |
|
|
( |
|
|
cd old/"$maindir" |
|
|
cd old/"$maindir" |
|
|
log_cmd pdflatex0.log pdflatex $latexopt "$mainbase" || compile_error=1 |
|
|
log_cmd pdflatex0.log pdflatex $latexopt "$mainbase" || compile_error=1 |
|
@ -478,8 +478,8 @@ if test "$flatten" = 1; then |
|
|
die "Failed to regenerate .bbl for old version" |
|
|
die "Failed to regenerate .bbl for old version" |
|
|
fi |
|
|
fi |
|
|
fi |
|
|
fi |
|
|
if [ ! -f "new/"$maindir$mainbase".bbl" ]; then |
|
|
|
|
|
verbose "Attempting to regenerate missing new/"$maindir$mainbase".bbl" |
|
|
|
|
|
|
|
|
if [ ! -f "new/$maindir$mainbase.bbl" ]; then |
|
|
|
|
|
verbose "Attempting to regenerate missing new/$maindir$mainbase.bbl" |
|
|
( |
|
|
( |
|
|
cd new/"$maindir" |
|
|
cd new/"$maindir" |
|
|
log_cmd pdflatex0.log pdflatex $latexopt "$mainbase" || compile_error=1 |
|
|
log_cmd pdflatex0.log pdflatex $latexopt "$mainbase" || compile_error=1 |
|
@ -493,12 +493,12 @@ if test "$flatten" = 1; then |
|
|
verbose "Running latexpand" |
|
|
verbose "Running latexpand" |
|
|
( |
|
|
( |
|
|
cd old/"$maindir" && |
|
|
cd old/"$maindir" && |
|
|
latexpand "$mainbase".tex "${latexpand[@]}" $bblexpand |
|
|
|
|
|
|
|
|
latexpand "$mainbase".tex "${latexpand[@]}" "${bblexpand[@]}" |
|
|
) > old-"$mainbase"-fl.tex \ |
|
|
) > old-"$mainbase"-fl.tex \ |
|
|
|| die "latexpand failed for old version" |
|
|
|| die "latexpand failed for old version" |
|
|
( |
|
|
( |
|
|
cd new/"$maindir" && |
|
|
cd new/"$maindir" && |
|
|
latexpand "$mainbase".tex "${latexpand[@]}" $bblexpand |
|
|
|
|
|
|
|
|
latexpand "$mainbase".tex "${latexpand[@]}" "${bblexpand[@]}" |
|
|
) > new-"$mainbase"-fl.tex \ |
|
|
) > new-"$mainbase"-fl.tex \ |
|
|
|| die "latexpand failed for new version" |
|
|
|| die "latexpand failed for new version" |
|
|
verbose_done |
|
|
verbose_done |
|
|