Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Formats > ePub

Notices

Reply
 
Thread Tools Search this Thread
Old 08-09-2020, 07:19 PM   #1
jcd1013
Junior Member
jcd1013 began at the beginning.
 
Posts: 2
Karma: 10
Join Date: Jan 2011
Device: Kindle for iPod
Question adding mass metadata to epub files from json?

Hello!

I recently inherited thousands of epub files (just under 10K) from a fanfiction site has now closed down and added them all to a new calibre library today. I only noticed afterwards that the epubs have no metadata attached to them and that there's a json file in the folder which contains all of the metadata.

How do I merge the metadata.json with the epubs? The thought of adding it back by hand makes me want to gnash teeth.

I use a Mac, OS 10.15.5, so if I do need an additional program, it would be helpful if it is Mac based.
jcd1013 is offline   Reply With Quote
Old 08-10-2020, 12:57 PM   #2
DNSB
Bibliophagist
DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.
 
DNSB's Avatar
 
Posts: 23,501
Karma: 105248689
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Forma, Clara HD, Lenovo M8 FHD, Paperwhite 4, Tolino epos
This may not be of much help to you but on the one occasion where I imported metadata from a json file for about 100 books, I converted the json file to csv, massaged the columns in Microsoft Excel (any spreadsheet program should work) and then used calibre's import list plugin to copy the metadata to the book entries. A bit of a PITA but it saved me a few hours.
DNSB is offline   Reply With Quote
Advert
Old 08-14-2020, 12:07 AM   #3
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 42,095
Karma: 19574558
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Use the ebook-meta command line program from calibre, with a script to read the json metadata and set it in the files. https://manual.calibre-ebook.com/gen...cli-index.html
kovidgoyal is offline   Reply With Quote
Old 08-14-2020, 02:38 AM   #4
Pippo53s03
Member
Pippo53s03 began at the beginning.
 
Posts: 18
Karma: 10
Join Date: Apr 2015
Device: Kobo Aura H2O 2ed
Quote:
Originally Posted by kovidgoyal View Post
Use the ebook-meta command line program from calibre, with a script to read the json metadata and set it in the files. https://manual.calibre-ebook.com/gen...cli-index.html
Should it be possible to have a script example?
Thanks!
Pippo53s03 is offline   Reply With Quote
Old 08-26-2020, 03:09 PM   #5
jcd1013
Junior Member
jcd1013 began at the beginning.
 
Posts: 2
Karma: 10
Join Date: Jan 2011
Device: Kindle for iPod
Quote:
Originally Posted by DNSB View Post
This may not be of much help to you but on the one occasion where I imported metadata from a json file for about 100 books, I converted the json file to csv, massaged the columns in Microsoft Excel (any spreadsheet program should work) and then used calibre's import list plugin to copy the metadata to the book entries. A bit of a PITA but it saved me a few hours.
This worked! I relabeled the columns in excel to fit the labels of my custom columns in Calibre, used the plugin and it combined the metadata and the books. Thank you!
jcd1013 is offline   Reply With Quote
Advert
Old 08-26-2020, 05:14 PM   #6
DNSB
Bibliophagist
DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.
 
DNSB's Avatar
 
Posts: 23,501
Karma: 105248689
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Forma, Clara HD, Lenovo M8 FHD, Paperwhite 4, Tolino epos
Quote:
Originally Posted by jcd1013 View Post
This worked! I relabeled the columns in excel to fit the labels of my custom columns in Calibre, used the plugin and it combined the metadata and the books. Thank you!
Good to hear it worked for you. For me, a few minutes of massaging the data was a lot less effort than manually entering the metadata.
DNSB is offline   Reply With Quote
Reply

Tags
calibre, epub, json

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
PDF Files; Metadata & File Names; Adding Physical Book Info Thunder_Struck Calibre 4 02-14-2019 12:16 AM
Question about metadata in epub files vs opf files machstem Calibre 3 06-19-2017 01:43 PM
How do I move JSON files? Rellwood Calibre 2 10-20-2015 01:26 AM
what are conflicted copy .db and .json files? mlevin77 Library Management 9 07-25-2014 01:28 PM
Adding metadata jacket to epub problem fxtrtr Library Management 1 07-08-2012 12:01 PM


All times are GMT -4. The time now is 06:33 AM.


MobileRead.com is a privately owned, operated and funded community.