View Single Post
Old 08-22-2014, 07:25 PM   #1
barsanuphe
Connoisseur
barsanuphe writes the songs that make the whole world sing.barsanuphe writes the songs that make the whole world sing.barsanuphe writes the songs that make the whole world sing.barsanuphe writes the songs that make the whole world sing.barsanuphe writes the songs that make the whole world sing.barsanuphe writes the songs that make the whole world sing.barsanuphe writes the songs that make the whole world sing.barsanuphe writes the songs that make the whole world sing.barsanuphe writes the songs that make the whole world sing.barsanuphe writes the songs that make the whole world sing.barsanuphe writes the songs that make the whole world sing.
 
Posts: 70
Karma: 40000
Join Date: Aug 2014
Location: Paris, France
Device: PW2, Kobo H20, Kobo Aura One
LibrarianSync: Kindle collections builder

What it is.

LibrarianSync is a Kindle collection builder, originally meant as a complement to Librarian, but which can be used completely independently.

It has been tested on a Kindle PW2 (EU, Wi-Fi) FW 5.4.5.1, and on a Touch FW 5.3. It probably works on other K5 devices. It apparently works on the Voyage as well.

It can use as a source:
  • a json file in native format (such as generated by Librarian when syncing, see below)
  • the json file automatically generated by the Calibre Kindle Collections plugin)
  • the folder structure inside the documents/ folder.

Using the json file, the entries can either remplace all existing collections or update existing collections. Using folder structure, all previously existing collections are dropped.

The native json format looks as follows:

Code:
{
  "library/Alexandre Dumas/Alexandre Dumas (2004) Les Trois Mousquetaires.mobi": ["gutenberg","french","not read"],
  "library/Alexandre Dumas/Alexandre Dumas (2011) Le Comte De Monte-Cristo.mobi": ["gutenberg","french","most awesome book ever"],
  "re:Alexandre Dumas (Père|Fils)": ["dumas"]
}
As shown in the last line, you can add (python) regular expressions instead of filenames (with a re: prefix); all matches will be added to the associated collection.

What is needed.

LibrarianSync comes as a KUAL menu entry. As such, it requires: a jailbroken PW2, MKK, KUAL, and python (snapshot > 0.10N-r10867).

For more information, see the README file on github.

Where it is.

The code resides on github.
See attachments for an up to date Kindle package.

Note: the code has moved to a separate repository as LibrarianSync has become something useful in its own right. Please update your git remotes to the new repository.

Where it comes from.

LibrarianSync is inspired by this thread.

Thanks to NiLuJe for all the contributions and continuous support, and kaznelson for his initial courageous sqlite investigations.

Feedback is very much welcome.

LibrarianSync Changelog

v20190103 - Refreshed package from latest sources, so as not to leave four year old packages around... -- NiLuJe
v1.10 - fixed when getting a null cdetype, added Voyage support.
v1.9 - fixed support of non-cloud aware devices
v1.8 - fixed collection appearing twice in FW 5.6
v1.7 - added support for regular expressions in librarian json when building collections with LibrarianSync.
v1.6 - fixed exporting collections, added downloading ebooks hosted over http by librarian.
v1.5 - package available for all k5 models.
v1.4 - updating collections is now faster.
v1.3 - calibre plugin json support & ability to export current collections (librarian and calibre plugin versions). While running the script, current operation now logged and displayed.
v1.2 - experimental calibre plugin json support & ability to export current collections to extensions/exported_collections.json.
v1.1 - experimental calibre plugin json support
v1.0 - original version
Attached Thumbnails
Click image for larger version

Name:	librariansync_v1.6.png
Views:	6548
Size:	21.8 KB
ID:	128575  
Attached Files
File Type: gz librariansync-1.0.tar.gz (7.0 KB, 1390 views)
File Type: gz librariansync-1.1.tar.gz (7.4 KB, 1010 views)
File Type: gz librariansync-1.2.tar.gz (8.0 KB, 1022 views)
File Type: gz librariansync-1.3.tar.gz (10.6 KB, 1096 views)
File Type: gz librariansync-1.4.tar.gz (10.9 KB, 1124 views)
File Type: gz librariansync-1.5.tar.gz (11.4 KB, 1067 views)
File Type: gz librariansync-1.6.tar.gz (12.4 KB, 1094 views)
File Type: gz librariansync-1.7.tar.gz (12.7 KB, 1475 views)
File Type: gz librariansync-1.8.tar.gz (12.7 KB, 1098 views)
File Type: gz librariansync-1.9.tar.gz (12.7 KB, 1375 views)
File Type: gz librariansync-1.10.tar.gz (13.3 KB, 5031 views)
File Type: gz librariansync-20190103.tar.gz (13.8 KB, 1138 views)

Last edited by NiLuJe; 10-01-2019 at 08:11 PM. Reason: LibrarianSync updated
barsanuphe is offline   Reply With Quote