Calibre is a great application for managing your ebook collections. It recognizes many different ebook formats. I use it as a reader for .mobi, and .epub files.
After installing calibre on my Ubuntu 12.04 box, I was annoyed to find that nautilus on the Unity desktop did not associate the calibre application with .mobi and .epub files. In other words, when I tried to open a .mobi file, nautilus didn’t know what application to launch. Furthermore, nautilus no longer gives you the option to right-click a file and add a custom application to handle it. You are forced to use a static list of already known applications.
There appears to be an error in the desktop launcher file for calibre. Edit the file /usr/share/applications/calibre.desktop.
Now nautilus should give you the option of selecting calibre from the list of applications. Right click on a .mobi or .epub file and select properties. Select the “Open with” tab and select the calibre application and click either “add” or “set as default”.
Solution 2 (creating a gnome desktop launcher) :
I’m going to show you how to create a desktop “launcher” with the basic contents required. You can modify the name and contents as needed to suit other applications and file formats.
Create a file named calibre.desktop in your home folder under ~/.local/share/applications/ (to make this available to all uses, you would copy this file to /usr/share/applications)
Add the following to that file and save.
Comment=e-book manager and reader
Now go back to nautilus and right click on any .mobi or .epub file and select properties. Click the “Open with” tab. Select show other applications. You should now see calibre in the list. Select calibre and click “set as default”.
You are done. Nautilus should now recognize calibre as the default application for opening .epub or .mobi files.
- The Gnome .desktop file specification: http://developer.gnome.org/desktop-entry-spec/
- The Calibre homepage: calibre-ebook.com