mronkko / ZoteroQuickLook

Implements QuickLook in Zotero
748 stars 82 forks source link

QuickLook opens multiple paths #40

Open Djoop opened 3 years ago

Djoop commented 3 years ago

Hi, thanks for the plugin which is very handy. When I open a pdf file using the plugin (latest release), it looks like the external reader (in my case, I use evince) tries to open two paths: one corresponding to the file I really want to open, and one for the path "/home/myusername". Hence I always have to close the second window. I don't know if this is a generic problem or if it is specific to evince, but it is a bit annoying. Am I the only one to have this problem?

bwiernik commented 3 years ago

How have you configured evince with the plugin?

Djoop commented 3 years ago

I went to the advanced setting and changed "extensions.zoteroquicklook.customviewcommand" to "/usr/bin/evince". Actually, I just tried to do it with the debug console, and when I try to open (with space bar) a zotero entry with e.g. 2 subentries (pdf document + webpage), evince opens 3 documents (the pdf, one window saying it fails to open the webpage, one window saying it fails to open file:///home/myusername), yet in the log evince is only called with two arguments:

(3)(+0000613): ZoteroQuickLook: opening viewer
(3)(+0000019): ZoteroQuickLook: calling a shell command: /usr/bin/evince /home/myusername/Zotero/storage/DLIYPKK3/books.html /home/myusername/Zotero/storage/AQJJ2PCJ/Steinwart_Christmann - 2008 - Support vector machines.pdf

I tried with other entries as well, and if I run the command that is written in the log it works well (except that spaces are not escaped, but ZoteroQuickLook does it obviously as it manages to open the files), in the sense that I don't see the extra window. So is there a anything happening in the plugin which is not in the log?