Package: calibre Version: 0.9.31+dfsg-1 Severity: wishlist Tags: patch I want this: Calibre is started automatically, when a ebook reader device, Kindle for example, connected to the PC.
That requires, 1) When a usb mass storage device is connected, gvfs can recognize if it is an ebook reader device or not, and set the "x_content_types" property of the mount to "x-content/ebook-reader" accordingly. 2) Calibre can be launched for "x-content/ebook-reader" mime type. For 1), no udev rules or shared mime info handles that yet. But if "driveinfo.calibre" can be found in a mounted directory tree, it is very likely a ebook reader device. Please add this file, and install it to /usr/share/mime/packages/calibre.xml (and run update-mime-database postinstall). calibre.sharedmimeinfo <?xml version="1.0" encoding="UTF-8"?> <mime-info xmlns="http://www.freedesktop.org/standards/shared-mime-info"> <mime-type type="x-content/ebook-reader"> <treemagic> <treematch type="file" path="driveinfo.calibre"/> </treemagic> </mime-type> </mime-info> For 2), Please change calibre.desktop, diff -pur calibre-0.9.31+dfsg/debian/local/calibre.desktop calibre-0.9.31+dfsg.modified/debian/local/calibre.desktop --- calibre-0.9.31+dfsg/debian/local/calibre.desktop 2013-05-21 14:56:12.000000000 +0800 +++ calibre-0.9.31+dfsg.modified/debian/local/calibre.desktop 2013-07-07 16:45:51.404192906 +0800 @@ -4,6 +4,7 @@ Name=calibre Comment=E-book library management Comment[es]=aplicación para la gestión de libros electrónicos Comment[de]=E-Book Bibliotheksverwaltung -Exec=calibre +Exec=calibre %f Icon=calibre Categories=Office;Database;FileTools;Viewer;Qt; +MimeType=x-content/ebook-reader; After these changes were made, you can modify GNOME system settings, select launching calibre when a ebook reader is connected. -- System Information: Debian Release: jessie/sid APT prefers unstable APT policy: (500, 'unstable') Architecture: amd64 (x86_64) Kernel: Linux 3.9-1-amd64 (SMP w/2 CPU cores) Locale: LANG=en_US.utf8, LC_CTYPE=en_US.utf8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/bash Versions of packages calibre depends on: ii calibre-bin 0.9.31+dfsg-1+b1 ii fonts-liberation 1.07.2-6 ii imagemagick 8:6.7.7.10-5 ii libjs-mathjax 2.2-1 ii poppler-utils 0.18.4-6 ii python-beautifulsoup 3.2.1-1 ii python-chardet 2.0.1-2 ii python-cherrypy3 3.2.2-2 ii python-cssselect 0.8-1 ii python-cssutils 0.9.10~b1-2 ii python-dateutil 1.5+dfsg-0.1 ii python-dbus 1.2.0-2 ii python-feedparser 5.1.2-1 ii python-imaging 1.1.7-4 ii python-lxml 3.2.0-1 ii python-markdown 2.3.1-1 ii python-mechanize 1:0.2.5-3 ii python-netifaces 0.8-2 ii python-pkg-resources 0.6.37-1 ii python-pyparsing 1.5.7+dfsg1-2 ii python-qt4 4.10.2-1 ii python-routes 1.13-2 ii python2.7 2.7.5-6 ii xdg-utils 1.1.0~rc1+git20111210-7 Versions of packages calibre recommends: ii python-dnspython 1.10.0-1 calibre suggests no packages. -- no debconf information
calibre.sharedmimeinfo
Description: XML document
diff -pur calibre-0.9.31+dfsg/debian/local/calibre.desktop calibre-0.9.31+dfsg.modified/debian/local/calibre.desktop --- calibre-0.9.31+dfsg/debian/local/calibre.desktop 2013-05-21 14:56:12.000000000 +0800 +++ calibre-0.9.31+dfsg.modified/debian/local/calibre.desktop 2013-07-07 16:45:51.404192906 +0800 @@ -4,6 +4,7 @@ Name=calibre Comment=E-book library management Comment[es]=aplicación para la gestión de libros electrónicos Comment[de]=E-Book Bibliotheksverwaltung -Exec=calibre +Exec=calibre %f Icon=calibre Categories=Office;Database;FileTools;Viewer;Qt; +MimeType=x-content/ebook-reader;

