09-14-2010, 12:52 AM | #1 |
Junior Member
Posts: 9
Karma: 10
Join Date: Feb 2010
Device: kindle
|
rename files based on metadata
Hi there,
I recently imported a large number of titles into my library which had really crappy filenames *and* metadata. I spent a good deal of time cleaning up the metadata, so now my metadata is perfect. However, the calibre directory structure still reflects the original filenames and authors. For instance, I have a directory named "Arthur C. Clarke" and one called "Arthur Charles Clark". Further, the filenames within those directories have not really been cleaned up either. I understand that calibre's directory structure is its own. However, is there a command/option to re-structure the directory tree based on the current metadata? I ask because when I connect to iTunes and export the files the old, messy, incorrect filenames show up in the iTunes "name" field, even though the files have perfectly good metadata. Thanks, Jon |
09-14-2010, 01:19 AM | #2 | |
Junior Member
Posts: 9
Karma: 10
Join Date: Feb 2010
Device: kindle
|
Quote:
However, the *filename* is still bogus. Is there any way to get calibre to change the filename to the metadata title so that it shows up with a reasonable name in iTunes? Thanks, Jon |
|
Advert | |
|
09-14-2010, 01:30 AM | #3 | |
US Navy, Retired
Posts: 9,864
Karma: 13806776
Join Date: Feb 2009
Location: North Carolina
Device: Icarus Illumina XL HD, Nexus 7
|
Quote:
I just went through my entire directory structure and found three directories that seemed wrong. They still had a book in them and when I went to check calibre's library it turns out that each of these authors I had made a typo. Once I changed the name in calibre, the directory was automatically changed too. Did these garbage directories have calibre's ID at the end of each book directory under the author's directory (see attached). Did you initially point calibre to a directory to use for its library that already had stuff/books in it? If you did that explains all of the junk lying around. calibre never messes with source documents. I've been told that if a directory had third party entries in it like thumbnails or search info then calibre can't change the directory just create a new one. Does any of the above ring a bell? I have 985 authors and 4000+ books and I haven't looked at my directory structure in a year and the only thing I found out of place were 3 typos I had entered in the metadata. Once these typos were corrected all of the suspect directories went away and the books were moved to their proper place. Good Luck, let us know what you discover. |
|
09-14-2010, 01:39 AM | #4 | ||
US Navy, Retired
Posts: 9,864
Karma: 13806776
Join Date: Feb 2009
Location: North Carolina
Device: Icarus Illumina XL HD, Nexus 7
|
Quote:
Quote:
Did you try Connecting to iTunes yet? |
||
09-14-2010, 01:53 AM | #5 | |
Wizard
Posts: 3,450
Karma: 10484861
Join Date: May 2006
Device: PocketBook 360, before it was Sony Reader, cassiopeia A-20
|
Quote:
In preferences, you can set how the name is supposed to look. Like {authors}/{series} {series_number} - {title} You can either leave the names inside the Calibre directory as they are and only use "Save files to disk" function, or you can use "Save files to disk" and then delete the books from inside Calibre and import them from this saved directory. |
|
Advert | |
|
09-14-2010, 01:59 AM | #6 | |
US Navy, Retired
Posts: 9,864
Karma: 13806776
Join Date: Feb 2009
Location: North Carolina
Device: Icarus Illumina XL HD, Nexus 7
|
Quote:
I admit I don't use iTunes so i am ignorant of the details but I thought I understood the basic theory of how calibre interacts with iTunes using the Connect to iTunes feature. |
|
09-14-2010, 03:42 AM | #7 | |
Junior Member
Posts: 9
Karma: 10
Join Date: Feb 2010
Device: kindle
|
Quote:
{author_sort}/{title} - {authors} However, I have (for instance) a book whose metadata contains: Author: Frank Herbert Title: Chapterhouse: Dune However, it shows up in iTunes' "name" column/field as: Dune Book 6 Chapterhouse: Dune The iTunes "Album" field is "Chapterhouse: Dune". The file name is: Chapterhouse_ Dune - Frank Herbert.epub So, how can I get both "Name" and "Album" in iTunes to be the "title" field from calibre? |
|
09-14-2010, 03:51 AM | #8 |
Junior Member
Posts: 9
Karma: 10
Join Date: Feb 2010
Device: kindle
|
This, by the way, matches the original name of the file when I imported it into calibre, before I cleaned up the metadata:
Dune Book 6 Chapterhouse_ Dune - Frank Herbert.epub Why won't this old, ugly name go away? How/why is calibre sending this to iTunes as the "Name" property? |
09-14-2010, 04:07 AM | #9 | |
US Navy, Retired
Posts: 9,864
Karma: 13806776
Join Date: Feb 2009
Location: North Carolina
Device: Icarus Illumina XL HD, Nexus 7
|
Quote:
|
|
09-14-2010, 05:23 AM | #10 |
Connoisseur
Posts: 67
Karma: 40
Join Date: Aug 2010
Device: iPad, Kindle Paperwhite
|
Have you checked that your ePUB does not already contain an iTunesMetadata.plist file?
iTunes will grab title/name/sorting from the metadata in the OPF , which should be right if you set it up in calibre, unless the ePUB in question already has a specific iTunes metadata file If no iTunesMetadata.plist is present saving the book to disk from calibre or using the "connect to iTunes" should give you the same basic fields for title/author/cover and author_sort |
09-14-2010, 10:28 AM | #11 | |
Junior Member
Posts: 9
Karma: 10
Join Date: Feb 2010
Device: kindle
|
Quote:
So...what's the best way to get rid of these .plist files for an entire library? I unzipped this specific epub to check, using the mac command line, but that's not tractable for hundreds of files. Is there a calibre setting to override the iTunesMetadata file? Thanks, Jon |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Creating TOC for books based on Text Files | crich70 | Kindle Formats | 4 | 09-13-2010 12:47 AM |
Language metadata in ePub files | HarryT | Calibre | 24 | 07-19-2010 10:24 PM |
how to export metadata and rename files? | argonaut | Calibre | 11 | 06-24-2010 08:30 AM |
Quick metadata from ePUB files | Jellby | ePub | 0 | 02-14-2010 06:11 AM |
How do you rename files on the reader? | RWJ | Sony Reader | 3 | 07-25-2008 10:58 AM |