Browse Source

Merge branch 'hb/bugfix/tectonic' into 'master'

Fix tectonic support

Closes #47

See merge request git-latexdiff/git-latexdiff!17
master^2
Matthieu Moy 5 years ago
parent
commit
0c23701c76
  1. 19
      git-latexdiff
  2. 15
      tests/tectonic/run-test.sh

19
git-latexdiff

@ -656,12 +656,14 @@ do
verbose_done verbose_done
done done
if [ "$ignorelatexerrors" = 1 ]; then
latexopt="$latexopt -interaction=batchmode"
elif [ "$quiet" = 1 ]; then
latexopt="$latexopt -interaction=nonstopmode"
else
latexopt="$latexopt -interaction=errorstopmode"
if test $tectonic != 1; then
if [ "$ignorelatexerrors" = 1 ]; then
latexopt="$latexopt -interaction=batchmode"
elif [ "$quiet" = 1 ]; then
latexopt="$latexopt -interaction=nonstopmode"
else
latexopt="$latexopt -interaction=errorstopmode"
fi
fi fi
# Option to use latexdiff --flatten instead of latexpand # Option to use latexdiff --flatten instead of latexpand
@ -789,6 +791,11 @@ elif test "$uselatexmk" = 1; then
compile_error=1 compile_error=1
error_msg="command 'latexmk' failed." error_msg="command 'latexmk' failed."
} }
elif test "$tectonic" = 1; then
log_cmd tectonic.log tectonic $latexopt "$mainbase.tex" || {
compile_error=1
error_msg="command 'tectonic' failed."
}
else else
log_cmd pdflatex1.log $LATEX_EXEC $latexopt "$mainbase" || { log_cmd pdflatex1.log $LATEX_EXEC $latexopt "$mainbase" || {
compile_error=1 compile_error=1

15
tests/tectonic/run-test.sh

@ -0,0 +1,15 @@
#!/bin/sh
die () {
echo "fatal: $*"
exit 1
}
cd "$(dirname "$0")/../bib" || exit
old=b9a200a6a0c45d6c594cb3c5473edd81a7edb52c
new=cbce899ba408849a471461bb9b5d648bf02039ef
echo "git latexdiff with --tectonic should work"
../../git-latexdiff --tectonic -v $old $new > tectonic.log 2>&1 ||
die "latexdiff with --tectonic failed."
Loading…
Cancel
Save