aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Runge <dave@sleepmap.de>2017-06-08 20:43:23 +0200
committerDavid Runge <dave@sleepmap.de>2017-06-08 20:43:23 +0200
commit967da2bbf1b99f05a1a04f9b6786448187a074be (patch)
treeda1c77da544e17234f8f4e67506e28c692ad0035
parent2b58efe8f69b74c1c705404d57de1e83e80f4125 (diff)
downloaddotfiles-967da2bbf1b99f05a1a04f9b6786448187a074be.tar.gz
dotfiles-967da2bbf1b99f05a1a04f9b6786448187a074be.tar.bz2
dotfiles-967da2bbf1b99f05a1a04f9b6786448187a074be.tar.xz
dotfiles-967da2bbf1b99f05a1a04f9b6786448187a074be.zip
bin/tex2pdf: Sending SIGHUP to mupdf if it has the pdf open already to only reload. Else open the file anew.
-rwxr-xr-xbin/tex2pdf5
1 files changed, 3 insertions, 2 deletions
diff --git a/bin/tex2pdf b/bin/tex2pdf
index 021682b..64287ae 100755
--- a/bin/tex2pdf
+++ b/bin/tex2pdf
@@ -79,9 +79,10 @@ function show_pdf()
check_mupdf_pid
echo "mupdf: ${dirname}/${filename}${output_suffix}."
if [ ! -z $mupdf_pid ]; then
- kill ${mupdf_pid}
+ kill -SIGHUP ${mupdf_pid}
+ else
+ mupdf ${dirname}/${filename}${output_suffix} &
fi
- mupdf ${dirname}/${filename}${output_suffix} &
}
function cleanup()