|
![]() |
|
Thread Tools | Search this Thread |
![]() |
#1 |
Enthusiast
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 43
Karma: 29000
Join Date: Jul 2009
Device: Kindle Paperwhite
|
Understanding the Advanced Options for adding metadata when unknown?
I will soon be getting my 505 over the next few days and have already been loading a few of my rtf collections into calibre. I noticed that for some reason it kept getting the title and author mixed up so had a play around with the advanced settings where it can be configured.
I tried to figure out how it was doing what it was doing by swapping the author and title locations though it still wouldn't work correctly. I was wondering if someone could either create a brief sticky with a guide for setting up our own masks or if someone could explain how I'd do one for the following styles? These aren't actually the books (I'm not at home at the minute and they're free books I was importing but can't recall the titles) but the styles are the same. King, Stephen - The Dark Tower 01 - Gunslinger J. K. Rowling - Harry Potter and the Goblet of Fire Would I have to create a mask for each style and swap them when loading into my library or could I create one master one that sets any text after and prior to '-' with a number in as a series name? |
![]() |
![]() |
![]() |
#2 |
Connoisseur
![]() ![]() ![]() ![]() ![]() Posts: 71
Karma: 422
Join Date: Jun 2009
Device: Palm Treo
|
Unfortunately calibre is doing stuff on my computer so I cannot test this , but it's possible that one of them will work for both titles as is. I assumes that in 1 the title is Gunslinger and series# 01 and series The Dark Tower, while in 2 the title is Harry Potter and the Goblet of Fire.
01 is proceeded by " " and followed by " - ". Let me know if it worked, if not I can try playing with it after calibre stops working. (?P<author>[.]+) - ((?P<series>[^0-9]+) (?P<series_index>\d+)? - )?(?P<title>[.]+) or (?P<author>[.]+?) - ((?P<series>[^0-9]+) (?P<series_index>\d+)? - )?(?P<title>[.]+) |
![]() |
![]() |
Advert | |
|
![]() |
#3 |
Connoisseur
![]() ![]() ![]() ![]() ![]() Posts: 71
Karma: 422
Join Date: Jun 2009
Device: Palm Treo
|
I just tested it, this seems to work with both "King, Stephen - The Dark Tower 01 - Gunslinger.txt" and with "J. K. Rowling - Harry Potter and the Goblet of Fire.txt"
Code:
(?P<author>.+?) - ((?P<series>.+) (?P<series_index>\d+) - )?(?P<title>.+) Matt btw, don't forget that when you test it, the test name needs to end with a ".xxx" i.e. any extension. |
![]() |
![]() |
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Metadata BUG adding books | Giuseppe Chillem | Calibre | 3 | 10-08-2010 05:13 PM |
what calibre does when adding books? (metadata) | jomaweb | Calibre | 1 | 02-06-2010 12:10 PM |
adding metadata | artemisblossom | Calibre | 3 | 09-25-2009 03:24 PM |
Adding online metadata using ISBN from CLI | EditorJack | Calibre | 17 | 01-20-2009 01:47 AM |
Advanced options for PDF files | npavkovic | Sony Reader Dev Corner | 5 | 02-22-2008 12:53 AM |