View Single Post
Old 11-07-2014, 04:33 PM   #1
WS64
WS64 ought to be getting tired of karma fortunes by now.WS64 ought to be getting tired of karma fortunes by now.WS64 ought to be getting tired of karma fortunes by now.WS64 ought to be getting tired of karma fortunes by now.WS64 ought to be getting tired of karma fortunes by now.WS64 ought to be getting tired of karma fortunes by now.WS64 ought to be getting tired of karma fortunes by now.WS64 ought to be getting tired of karma fortunes by now.WS64 ought to be getting tired of karma fortunes by now.WS64 ought to be getting tired of karma fortunes by now.WS64 ought to be getting tired of karma fortunes by now.
 
WS64's Avatar
 
Posts: 661
Karma: 506380
Join Date: Aug 2010
Location: Germany
Device: Kobo Aura / PB Lux 2 / Bookeen Frontlight / Kobo Mini / Nook Color
[GUI Plugin] Clean Metadata

My first plugin...

This plugin edits the metadata of selected books in your library.
You can either just mark the books that will get changed or directly execute the changes.
The main purpose is to mass-update many books at once that have pretty messed up metadata.

Main Features:
  • Cleanup German umlauts in title: "Boser Ueberfall und Duell der Daemonen" => "Boser Überfall und Duell der Dämonen"
  • Cleanup titles: "This is a book title (German Edition)" / "This is a book title. A novel" / "This_is_a_book_title" => "This is a book title"
  • Get series info from titles: "Harry Potter 3: The Prisoner of Azkaban" => title: "The Prisoner of Azkaban", series: "Harry Potter", series_index: 3
  • Cleanup authors: "Lastname, A B.C. Firstname; Anotherlastname, Anotherfirstname" => 1: "A. B. C. Firstname Lastname", 2: "Anotherfirstname Anotherlastname"
  • Swap author and title if title matches an existing author: title: "Stephen King", author: "Cujo" => title: "Cujo", author: "Stephen King" *if* there is already one othebook in your library with author "Stephen King"

Special Notes:
  • Requires Calibre 2.0.0 or later
  • Use at your own risk! Due to some false findings you might create more damage to your metadata than you will repair using this plugin!
  • So far I completely failed to save the settings of the two checkboxes, the interfacedemo plugin was no great help for this. If someone could help me here that would be great, but beware, I'm a complete newbie to Python and Qt5!

Installation Notes:
  1. Download the attached zip file and install the plugin/restart Calibre/add to context menu as described in the Introduction to plugins thread.

Running from command line:
  • not supported

Paypal Donations:
  • nope. I wrote this mainly for myself and don't want to send money to myself!

Version History:

Spoiler:

Version 0.0.6 - 22 Nov 2014
Renamed from "WS64 Cleanup" to "Clean Metadata"

Version 0.0.5 - 20 Nov 2014
New function: Find Duplicate author candidates

Version 0.0.4 - 09 Nov 2014
Bugfixes and minor improvements

Version 0.0.3 - 07 Nov 2014
Initial release. Since just three days ago I have not seen any Python/Qt5 source code the code is far from perfect and probably still very buggy.

Attached Thumbnails
Click image for larger version

Name:	screenshot.jpg
Views:	4589
Size:	44.6 KB
ID:	130745  
Attached Files
File Type: zip Clean Metadata.zip (13.4 KB, 191100 views)

Last edited by WS64; 11-22-2014 at 04:09 AM.
WS64 is offline   Reply With Quote