fb2reader
fb2reader copied to clipboard
Unable to associate local FB2 on Linux "right way"
Solution mentioned as a reply to #8 works, but has a disadvantage - I can't select other FB2 app (like crqt-ng) in a "Open with...".
$ xdg-mime query filetype some_book_file.fb2
application/x-fictionbook+xml
$ echo ${ff:=$(xdg-mime query default application/x-fictionbook+xml)}
firefox-esr.desktop
$ sed -e '/^MimeType=/ s@$@application/x-fictionbook+xml;@' \
/usr/share/applications/$ff \
> ~/.local/share/applications/$ff
$ update-mime-database ~/.local/share/mime
$ update-desktop-database ~/.local/share/applications
$ xdg-open some_book_file.fb2
Then firefox asks whether I want to open it with "Firefox" or save and after clicking open with firefox it opens empty tabs named as file in a loop. :-(
Seems it's unsupported in Firefox. :-(
Well, that is the exact duplicate of the #8 issue. Firefox treats application/fictionbook+xml as some generic mime type, and does not trigger the extension.
the link above is a bit unrelated, as it is about Progressive Web Apps, not Firefox extensions.