To open DjVu files on a Mac, I've downloaded Okular. Unfortunately Okular's Info.plist doesn't declare any supported file formats.
I've manually selected okular.app in Get Info > Open With > All Applications. Now, when I click on a DjVu file in Finder, Okular is started but the file is not opened. When I run
ps -wwp "$(pgrep okular)" -o command
it shows that the path to the DjVu file was not passed to Okular's binary
COMMAND
/Applications/okular.app/Contents/MacOS/okular
Running
open -a /Applications/okular.app PATH_TO_DJVU
produces the same result.
However, explicitly passing the path to Okular's binary works:
/Applications/okular.app/Contents/MacOS/okular PATH_TO_DJVU
Is there a way to force Finder to do so?