From 32c39a62998ca144b652955a9a5491f68846a835 Mon Sep 17 00:00:00 2001 From: Don Armstrong Date: Tue, 9 May 2017 13:02:06 -0700 Subject: [PATCH] use okular in preference to evince if it is installed --- evince_annot | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/evince_annot b/evince_annot index 65cd452..8c66a18 100755 --- a/evince_annot +++ b/evince_annot @@ -22,12 +22,16 @@ fi; (cd "$TMPDIR/b" chmod u+w "file.pdf" - ## evince really should just use the same document-directory - gsettings set org.gnome.Evince document-directory "'file://$TMPDIR/b'"; - evince "file.pdf" + if which okular > /dev/null 2>&1; then + okular "file.pdf" + else + ## evince really should just use the same document-directory + gsettings set org.gnome.Evince document-directory "'file://$TMPDIR/b'"; + evince "file.pdf" + fi; ); -if !cmp "$TMPDIR/b/file.pdf" "$TMPDIR/c/file.pdf"; then +if ! cmp "$TMPDIR/b/file.pdf" "$TMPDIR/c/file.pdf"; then (cd "$TMPDIR"; diff -Nura a b ) | qprint --encode --binary > "$ANNOT_FILE" fi; -- 2.39.2