View Single Post
Old 12-04-2014, 11:00 PM   #10
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)
There is NO cli equivalent to auto-add. calibredb add is the cli for the Add books icon on the toolbar, which is a manual operation that does not delete books after adding.


Just put both commands on separate lines, they will be invoked as separate commands.

Code:
/Applications/calibre.app/Contents/console.app/Contents/MacOS/calibredb add --with-library=/Volumes/Ministack/Calibre\ Library --recurse /Users/IS/Dropbox/Reading\ Books/
rm -r /Users/IS/Dropbox/Reading\ Books/*
It will remove all files from the given folder, regardless of whether they are ebooks or whether they have been added to calibre -- although the previous command implies that it has been added.

Last edited by eschwartz; 12-05-2014 at 12:18 AM. Reason: only delete contents of folder, not folder itself
eschwartz is offline   Reply With Quote