Comment 7 for bug 883616

Revision history for this message
Kovid Goyal (kovid) wrote : Re: [Bug 883616] Re: IREX DR Driver root directory

How about the following change:

def get_ebook_dir_main(self, for_upload=False):
    if for_upload:
       return 'ebooks' # or 'Books' for the 800
    return ''

This will mean tha calibre will continue to place books in the ebooks
directory, but it will be able to scan all directories for books.

Kovid.

On Tue, Nov 08, 2011 at 11:24:42AM -0000, Glenn Barnich wrote:
> On 08 Nov 2011, at 11:42, Kovid Goyal wrote:
>
> > So, really the only change you need is setting EBOOK_DIR_MAIN = ''?
>
> yes, both in the DR1000 section and in the DR800 section
>
>
> > Is
> > the custom firmware unable to access files under /ebooks?
>
> If by custom you mean the latest (beta and also final) firmware from
> IREX, both the custom and the original firmwares are able to access
> files in this directory, but in fact for both firmwares, the final
> directory structure is and always has been somewhat ugly. Concretely for
> the latest beta firmware and the standard plugin you end up with
>
> DR1000
>
> /Books (not accessible by calibre)
> /ebooks/ (contains all books loaded by calibre, including a directory /news with the news from calibre ...)
> /News (not accessible by calibre)
>
> DR800
>
> /Books (contains all books loaded by calibre, including a directory /news with the news from calibre ...)
> /News (not accessible by calibre)
>
>
> > I ask because
> > I hate making behavioral changes, unless they are absolutely necessary.
>
> They are of course not absolutely necessary, because after using calibre
> to put books and news, one can of course move the files on the devices
> by hand in the appropriate directories to use the full features of the
> reader. But this is not optimal of course and somehow defeats the
> purpose.
>
> I do not think that this will be a behavioral change that will
> negatively affect any users with the original or latest firmware. In any
> case, the old behavior of the plugin can always be reproduced just by
> including /ebooks respectively /Books in the save template.
>
>
> >
> > --
> > You received this bug notification because you are subscribed to the bug
> > report.
> > https://bugs.launchpad.net/bugs/883616
> >
> > Title:
> > IREX DR Driver root directory
> >
> > Status in calibre: e-book management:
> > Incomplete
> >
> > Bug description:
> > Loading image...done
> > # Bazaar merge directive format 2 (Bazaar 0.90)
> > # revision_id: <email address hidden>
> > # target_branch: http://bazaar.launchpad.net/~kovid/calibre/trunk/
> > # testament_sha1: 38c5471c63aa74698f2c1bebff24d3346ce29feb
> > # timestamp: 2011-10-29 20:36:54 +0200
> > # base_revision_id: <email address hidden>-\
> > # i239c4whbhw4y23a
> > #
> > # Begin patch
> > === modified file 'src/calibre/devices/irexdr/driver.py'
> > --- src/calibre/devices/irexdr/driver.py 2010-10-04 03:18:26 +0000
> > +++ src/calibre/devices/irexdr/driver.py 2011-10-29 18:36:00 +0000
> > @@ -27,24 +27,27 @@
> > BCD = [0x322]
> >
> > VENDOR_NAME = 'IREX'
> > - WINDOWS_MAIN_MEM = 'DR1000'
> > +
> > + EBOOK_DIR_MAIN = ''
> > + EBOOK_DIR_CARD_A = ''
> > +
> > + WINDOWS_MAIN_MEM = ''
> >
> > OSX_MAIN_MEM = 'iRex DR1000 Media'
> > -
> > MAIN_MEMORY_VOLUME_LABEL = 'IRex Digital Reader 1000 Main Memory'
> >
> > - EBOOK_DIR_MAIN = 'ebooks'
> > - DELETE_EXTS = ['.mbp']
> > +
> > + DELETE_EXTS = []
> > SUPPORTS_SUB_DIRS = True
> >
> > class IREXDR800(IREXDR1000):
> > name = 'IRex Digital Reader 800 Device Interface'
> > description = _('Communicate with the IRex Digital Reader 800')
> > PRODUCT_ID = [0x002]
> > - WINDOWS_MAIN_MEM = 'DR800'
> > + WINDOWS_MAIN_MEM = ''
> > FORMATS = ['epub', 'pdb', 'html', 'pdf', 'txt']
> >
> > - EBOOK_DIR_MAIN = 'Books'
> > + EBOOK_DIR_MAIN = ''
> > DELETE_EXTS = []
> > SUPPORTS_SUB_DIRS = True
> >
> >
> > # Begin bundle
> > IyBCYXphYXIgcmV2aXNpb24gYnVuZGxlIHY0CiMKQlpoOTFBWSZTWXDszVgAAbzfgEAQUOf/936v
> > nMq/7//wUAQars3Dbp0Hu9tm8JJI00jTBMp6TAmI00IDTyGmkaZHqaDJEMCZNTU2k0aNAAAANGgA
> > CUE0FNMqeZCnqbU2o9IDQ9RoGgaB6jQNqknpo0j0ieTSfqh6gyMQAABoPSAJSU2k9MmqeSP1T2pq
> > ZNN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/oCTkswFc9KxNkFVFTiJu8BZxMQAYHCuzvYj
> > WgpM9oRxiApqDrSL4qUloY263Ib5Ui07CeMWsRWhqVlbrYUErRQt2F7uwZWUpQLAX1njuEqUmolt
> > unzQLyWT9FcscOHBzReC2TGxSYVXHRAQ68C8WxU3qJOuOYkVC2SKOrvdOSNgvmotqwzUOcjQcI8B
> > QX0xpYjFyqio5RFI0hSF6QIFKRxaAvL2YTG3D/F3JFOFCQcOzNWA
> >
> > To manage notifications about this bug go to:
> > https://bugs.launchpad.net/calibre/+bug/883616/+subscriptions
>
> --
> You received this bug notification because you are subscribed to
> calibre.
> https://bugs.launchpad.net/bugs/883616
>
> Title:
> IREX DR Driver root directory
>
> Status in calibre: e-book management:
> Incomplete
>
> Bug description:
> Loading image...done
> # Bazaar merge directive format 2 (Bazaar 0.90)
> # revision_id: <email address hidden>
> # target_branch: http://bazaar.launchpad.net/~kovid/calibre/trunk/
> # testament_sha1: 38c5471c63aa74698f2c1bebff24d3346ce29feb
> # timestamp: 2011-10-29 20:36:54 +0200
> # base_revision_id: <email address hidden>-\
> # i239c4whbhw4y23a
> #
> # Begin patch
> === modified file 'src/calibre/devices/irexdr/driver.py'
> --- src/calibre/devices/irexdr/driver.py 2010-10-04 03:18:26 +0000
> +++ src/calibre/devices/irexdr/driver.py 2011-10-29 18:36:00 +0000
> @@ -27,24 +27,27 @@
> BCD = [0x322]
>
> VENDOR_NAME = 'IREX'
> - WINDOWS_MAIN_MEM = 'DR1000'
> +
> + EBOOK_DIR_MAIN = ''
> + EBOOK_DIR_CARD_A = ''
> +
> + WINDOWS_MAIN_MEM = ''
>
> OSX_MAIN_MEM = 'iRex DR1000 Media'
> -
> MAIN_MEMORY_VOLUME_LABEL = 'IRex Digital Reader 1000 Main Memory'
>
> - EBOOK_DIR_MAIN = 'ebooks'
> - DELETE_EXTS = ['.mbp']
> +
> + DELETE_EXTS = []
> SUPPORTS_SUB_DIRS = True
>
> class IREXDR800(IREXDR1000):
> name = 'IRex Digital Reader 800 Device Interface'
> description = _('Communicate with the IRex Digital Reader 800')
> PRODUCT_ID = [0x002]
> - WINDOWS_MAIN_MEM = 'DR800'
> + WINDOWS_MAIN_MEM = ''
> FORMATS = ['epub', 'pdb', 'html', 'pdf', 'txt']
>
> - EBOOK_DIR_MAIN = 'Books'
> + EBOOK_DIR_MAIN = ''
> DELETE_EXTS = []
> SUPPORTS_SUB_DIRS = True
>
>
> # Begin bundle
> IyBCYXphYXIgcmV2aXNpb24gYnVuZGxlIHY0CiMKQlpoOTFBWSZTWXDszVgAAbzfgEAQUOf/936v
> nMq/7//wUAQars3Dbp0Hu9tm8JJI00jTBMp6TAmI00IDTyGmkaZHqaDJEMCZNTU2k0aNAAAANGgA
> CUE0FNMqeZCnqbU2o9IDQ9RoGgaB6jQNqknpo0j0ieTSfqh6gyMQAABoPSAJSU2k9MmqeSP1T2pq
> ZNNqaZMTJoADCBoMBo1bSnqU+2XabNZFy673ZKaNsBRUTY1h2weUqaAE4DKjfNzW7rzDMj8+Ye8c
> Ko8+ip75BVM9pGhE7j8zj5F6sMe36NqXx7N/LBTw9nGveW+jU+9r+Uc79ESiEaJOfiqvdQz5pYs+
> Z7p3dmFOZHWjpR5MasUx7z3i4PcUZOLaZip2fhftQWGhXBFiWEbNfZLoTRZGKLC89RYi9TJYwkip
> 0hR2EFbJGQGojI6O6ZJmHLlWaV6oM1YM6I3s38zlZoGZMjX04wgUQMIm9Iium/3l/6TddyUVwczG
> S6YWTCRVEr7Lbb9YXLnYRBRrneooLGubFfMGKIF2qBMCgumy2i1sEA91SXii44yp8gVRa0zcfu4O
> CynRNTGh6YTtWUUGGu6QUIxiHRRgoDbXQGstYaj+l8EhYhXiAyBwH4qXBIVMezLKCE0wFsjGNiXg
> 5cYqHE1ptZiUc76LJjfs531wsGZ18yhkYqBwWbcloXFdrZx0qTKjrarKtNNz7NTNOgTckyLRYICS
> Dd/OzC6cF5rNbF3js2JRhy3BxvTsmPRUN5w3+Tl4pxmaP7sC+Z7s/otaYpi/rMROi5DWmkcKaUoc
> 9P+5o6SYfFymr5J7i0tLc/Q4OGaIZaWj7fjuPNiNj6N2pWTbw2AcAhukqqIRKl3fChGqtLAnUb/t
> 3G71Sd+KaU25e8HmAFlBk6zKjnuOFg0RWgArerGdBLvMHMA5ykMdebwKCcv4aLylTOS8DG+GK8SB
> mLFxXBe3Dgz4etpoRK3Q12WPCdfGyWQyZYzTr0uNuyDzrdRMFFVahRCrp0SS1NJ0bXSts/jiem+f
> CZVuWu2LHY/VmxFYSU2CwBH3OJlDOSbbqCrK5TxFBDlt1aBVuXYO6jqGihHKjEL/JYAyaxFIN7LE
> uDLBFFlWETztWnNNUA5o/RVAOhSVpVpIRk+Q4J1/EYS1A4SdK+ikLHgyFZAHhyBYRwBYlFJ5QkyR
> LESn9pmUDHJzaKFggGUNusnqpWOZsjniy4zC1EJA/oCTkswFc9KxNkFVFTiJu8BZxMQAYHCuzvYj
> WgpM9oRxiApqDrSL4qUloY263Ib5Ui07CeMWsRWhqVlbrYUErRQt2F7uwZWUpQLAX1njuEqUmolt
> unzQLyWT9FcscOHBzReC2TGxSYVXHRAQ68C8WxU3qJOuOYkVC2SKOrvdOSNgvmotqwzUOcjQcI8B
> QX0xpYjFyqio5RFI0hSF6QIFKRxaAvL2YTG3D/F3JFOFCQcOzNWA
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/calibre/+bug/883616/+subscriptions
>
> !DSPAM:3,4eb912e316201833235104!
>
>

--
_____________________________________

Dr. Kovid Goyal
http://www.kovidgoyal.net
http://calibre-ebook.com
_____________________________________