Openning Zotero on Debian 13 (on zotero.desktop)

edited 10 days ago
What is

exec=bash -c "$(dirname $(realpath $(echo %k | sed -e 's/^file:\\/\\///')))/zotero -url %U"

in zotero.desktop? It does not works

Let's assume I follow the suggestion and save zotero in /opt/zotero. Then,

exec=bash -c "/opt/zotero/zotero -url %U"

works. But, what the first command tries does not produce this...
  • I am facing the same problem. Here is some debug info:
    $ desktop-file-validate zotero.desktop
    > zotero.desktop: error: value "bash -c "$(dirname $(realpath $(echo %k | sed -e 's/^file:\//\\///')))/zotero -url %U"" for key "Exec" in group "Desktop Entry" contains a non-escaped character '$' in a quote, but it should be escaped with two backslashes ("\\$")
    zotero.desktop: error: value "bash -c "$(dirname $(realpath $(echo %k | sed -e 's/^file:\//\\///')))/zotero -url %U"" for key "Exec" in group "Desktop Entry" contains a non-escaped character '$' in a quote, but it should be escaped with two backslashes ("\\$")
    zotero.desktop: error: value "bash -c "$(dirname $(realpath $(echo %k | sed -e 's/^file:\//\\///')))/zotero -url %U"" for key "Exec" in group "Desktop Entry" contains a non-escaped character '$' in a quote, but it should be escaped with two backslashes ("\\$")
    zotero.desktop: error: value "bash -c "$(dirname $(realpath $(echo %k | sed -e 's/^file:\//\\///')))/zotero -url %U"" for key "Exec" in group "Desktop Entry" contains a quote which is not closed


    System specs:
    Zotero version: 8.0.3
    OS: Ubuntu 24.04 (& Trisquel)
  • I get the same output with the command desktop-file-validate .local/share/applications/zotero.desktop, but it does not prevent the file to work as expected.

    Zotero 8.0.3
    Ubuntu 22.04.5 LTS
  • @poettli
    Thanks for pointing that out, turns out I'm able to run Zotero from the menu item as well. (i.e. by clicking on menu -> Zotero). But when I try to open them from Application launcher (Alt+f2) it fails. Changing the exec to direct path (/path-to-zotero/zotero) fixes the issue.
Sign In or Register to comment.