Adding books with different filename structures
I'm pretty new to Calibre so please excuse me if this has been answered before. I looked but couldn't find an answer.
I want to import a library that uses this naming convention:
<Author> - <Series> <series number> - <title>
for books that are not part of a series, the files look like this:
<Author> - <title>
Examples:
Stieg Larsson - Millenium 03 - Girl Who Kicked the Hornets' Nest, The.epub
Stephen King - The Dead Zone.epub
Is there a regular expression that will import both types and put the fields where they should be?
After a lot of reading and trying things, I discovered that this expression:
(?P<author>[^_]+) - (?P<series>.+)(?P<series_index> [0-9]+) - (?P<title>.+)
Will work for the first case, but not the second. Any suggestions? There are a lot of books and I'd rather not manually separate them.
|