View Single Post
Old 11-26-2014, 04:50 PM   #7
eschwartz
Ex-Helpdesk Junkie
eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.
 
eschwartz's Avatar
 
Posts: 19,421
Karma: 85400180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
Quote:
Originally Posted by Josieb1 View Post
Thanks for the link to the other thread, my only issue is i have a few thousand I'd like to add a text file to and they all have multiple formats. Is there a quick way of adding an empty text file to a bulk set of books?
Yes, via the command-line.

Code:
for i in $ids; do
    calibredb add_format $i /path/to/empty.txt
done
should work in bash, so that covers linux and OSX. Something similar would work on Windows, but I can never keep batch syntax straight.

You would need to replace ids with a list of all ids in calibre, when I get back to a computer I will try to make a search that produces the ids, something with calibredb list, maybe, but it might require jshon or some other bash json parser, and I have no idea on windows.

Last edited by eschwartz; 11-26-2014 at 04:56 PM.
eschwartz is offline   Reply With Quote