Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Formats > ePub

Notices

Reply
 
Thread Tools Search this Thread
Old 08-09-2020, 06:19 PM   #1
jcd1013
Junior Member
jcd1013 began at the beginning.
 
Posts: 4
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, 11:57 AM   #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: 35,399
Karma: 145435140
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 online now   Reply With Quote
Advert
Old 08-13-2020, 11:07 PM   #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: 43,857
Karma: 22666666
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, 01:38 AM   #4
Pippo53s03
Member
Pippo53s03 began at the beginning.
 
Posts: 19
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, 02:09 PM   #5
jcd1013
Junior Member
jcd1013 began at the beginning.
 
Posts: 4
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, 04: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: 35,399
Karma: 145435140
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 online now   Reply With Quote
Reply

Tags
calibre, epub, json


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-13-2019 11:16 PM
Question about metadata in epub files vs opf files machstem Calibre 3 06-19-2017 12:43 PM
How do I move JSON files? Rellwood Calibre 2 10-20-2015 12:26 AM
what are conflicted copy .db and .json files? mlevin77 Library Management 9 07-25-2014 12:28 PM
Adding metadata jacket to epub problem fxtrtr Library Management 1 07-08-2012 11:01 AM


All times are GMT -4. The time now is 11:34 PM.


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