Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre > Related Tools

Notices

Reply
 
Thread Tools Search this Thread
Old 12-28-2017, 04:28 PM   #1
sealbeater
Banned
sealbeater ought to be getting tired of karma fortunes by now.sealbeater ought to be getting tired of karma fortunes by now.sealbeater ought to be getting tired of karma fortunes by now.sealbeater ought to be getting tired of karma fortunes by now.sealbeater ought to be getting tired of karma fortunes by now.sealbeater ought to be getting tired of karma fortunes by now.sealbeater ought to be getting tired of karma fortunes by now.sealbeater ought to be getting tired of karma fortunes by now.sealbeater ought to be getting tired of karma fortunes by now.sealbeater ought to be getting tired of karma fortunes by now.sealbeater ought to be getting tired of karma fortunes by now.
 
Posts: 666
Karma: 1752814
Join Date: Jan 2008
Device: Sony Reader PRS-505 : Onyx Boox Max : Sony PRS-900 : Onyx Kepler Pro
Good scripts for managing ebooks.

https://github.com/na--/ebook-tools

I'm not the author but I have found these scripts to be invaluable.

Hopefully others will find them helpful.
sealbeater is offline   Reply With Quote
Old 12-28-2017, 04:39 PM   #2
JSWolf
Resident Curmudgeon
JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.
 
JSWolf's Avatar
 
Posts: 74,027
Karma: 129333114
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
What do these scripts do and what OS are they for?
JSWolf is offline   Reply With Quote
Advert
Old 12-28-2017, 04:47 PM   #3
sealbeater
Banned
sealbeater ought to be getting tired of karma fortunes by now.sealbeater ought to be getting tired of karma fortunes by now.sealbeater ought to be getting tired of karma fortunes by now.sealbeater ought to be getting tired of karma fortunes by now.sealbeater ought to be getting tired of karma fortunes by now.sealbeater ought to be getting tired of karma fortunes by now.sealbeater ought to be getting tired of karma fortunes by now.sealbeater ought to be getting tired of karma fortunes by now.sealbeater ought to be getting tired of karma fortunes by now.sealbeater ought to be getting tired of karma fortunes by now.sealbeater ought to be getting tired of karma fortunes by now.
 
Posts: 666
Karma: 1752814
Join Date: Jan 2008
Device: Sony Reader PRS-505 : Onyx Boox Max : Sony PRS-900 : Onyx Kepler Pro
Quote:
Originally Posted by JSWolf View Post
What do these scripts do and what OS are they for?
For unix and there are docker images.

From the page:

This is a collection of bash shell scripts for automated and semi-automated organization and management of large ebook collections. It contains the following tools:

organize-ebooks.sh is used to automatically organize folders with potentially huge amounts of unorganized ebooks. This is done by renaming the files with proper names and moving them to other folders:

By default it searches the supplied ebook files for ISBNs, downloads the book metadata (author, title, series, publication date, etc.) from online sources like Goodreads, Amazon and Google Books and renames the files according to a specified template.
If no ISBN is found, the script can optionally search for the ebooks online by their title and author, which are extracted from the filename or file metadata.
Optionally an additional file that contains all the gathered ebook metadata can be saved together with the renamed book so it can later be used for additional verification, indexing or processing.
Most ebook types are supported: .epub, .mobi, .azw, .pdf, .djvu, .chm, .cbr, .cbz, .txt, .lit, .rtf, .doc, .docx, .pdb, .html, .fb2, .lrf, .odt, .prc and potentially others. Even compressed ebooks in arbitrary archive files are supported. For example a .zip, .rar or other archive file that contains the .pdf or .html chapters of an ebook can be organized without a problem.
Optical character recognition (OCR) can be automatically used for.pdf, .djvu and image files when no ISBNs were found in them by the fast and straightforward conversion to .txt. This is very useful for scanned ebooks that only contain images or were badly OCR-ed in the first place.
Files are checked for corruption (zero-filled files, broken pdfs, corrupt archive, etc.) and corrupt files can optionally be moved to another folder.
Non-ebook documents, pamphlets and pamphlet-like documents like saved webpages, short pdfs, etc. can also be detected and optionally moved to another folder.
asciicast

interactive-organizer.sh can be used to interactively and manually organize ebook files quickly. A good use case is the organization of the files that could not be automatically organized by the organize-ebooks.sh script. It can also be used to semi-automatically verify the organized files by the above script and potentially reorganize some of them:

If organize-ebooks.sh was called with --keep-metadata, the interactive organizer compares the old filename with the new one and shows suspicious differences between the two. Wrongly renamed files can be interactively renamed with this script.
There is a quick mode that skips files with names that contain the all of the original filename's tokens. Differences due to diacritical marks and truncated words are handled intelligently. A list of allowed differences can be configured and interactively updated while organizing the books.
The script can restore files back to their original location or move them to one of many different pre-configurable output folders.
Ebooks can be converted to .txt and shown with less directly in the current terminal or they can be opened with an external viewer without exiting from the interactive organization.
Books can be semi-automatically renamed by looking up their metadata (by ISBN or title) online.
find-isbns.sh tries to find valid ISBNs inside a file or in stdin if no file was specified. Searching for ISBNs in files uses progressively more resource-intensive methods until some ISBNs are found, see the documentation below for more details.

convert-to-txt.sh converts the supplied file to a text file. It can optionally also use OCR for .pdf, .djvu and image files.

rename-calibre-library.sh traverses a calibre library folder and renames all the book files in it by reading their metadata from calibre's metadata.opf files.

split-into-folders.sh splits the supplied ebook files (and the accompanying metadata files if present) into folders with consecutive names that each contain the specified number of files.

All of the tools use a library file lib.sh that has useful functions for building other ebook management scripts. More details for the different script options and parameters can be found in the Usage, options and configuration section.


I commented in another thread but personally I use this to preprocess books before adding them to Calibre.

Example processing some Project Gutenberg books.

OK: ./14595/pg14595.epub
TO: /home/sealbeater/ebooks/uncertain/Oliver Optic/Oliver Optic - The Soldier Boy, Or, Tom Somers in the Army a Story of the Great Rebellion (2012) [9783847200888].epub

OK: ./14593/pg14593.epub
TO: /home/sealbeater/ebooks/uncertain/Alexander Lange Kielland/Alexander Lange Kielland - Norse Tales and Sketches (2008) [9781406876185].epub

OK: ./14598/pg14598.epub
TO: /home/sealbeater/ebooks/uncertain/Harold MacGrath/Harold MacGrath - The Goose Girl (2012) [9783847200895].epub

It supports output templates so you have some flexibility with how you want file data arranged.
sealbeater is offline   Reply With Quote
Old 12-28-2017, 05:18 PM   #4
JSWolf
Resident Curmudgeon
JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.
 
JSWolf's Avatar
 
Posts: 74,027
Karma: 129333114
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
Thanks.
JSWolf is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Managing multi-file eBooks larabell Library Management 0 06-05-2012 03:09 AM
Calibre help managing my ebooks book64 Library Management 7 01-16-2012 11:51 AM
Managing my ebooks pwalker8 Apple Devices 6 07-14-2011 03:16 PM
Managing my ebooks Pier Calibre 4 09-08-2009 05:03 AM
Using perl scripts to produce .IMP ebooks and more... nrapallo IMP 43 04-22-2009 12:05 AM


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


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