View Single Post
Old 03-07-2013, 10:33 PM   #10
JimmXinu
Plugin Developer
JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.
 
JimmXinu's Avatar
 
Posts: 6,318
Karma: 3966249
Join Date: Dec 2011
Location: Midwest USA
Device: Kindle Paperwhite(10th)
Quote:
Originally Posted by kovidgoyal View Post
@JimmXinu: It is perfectly possible to use plugins from the calibre command line, see the modify epub plugin for an example.
Possible, but perfectly is a stretch--at least right now.

Currently, on my system at least (Win7, calibre 0.9.21 64bit), 'calibre-debug -e' isn't effective because calibre-debug is taking all the options and not passing them to the called py file.

Using the modify epub example:
Spoiler:
Code:
C:\Users\username\Desktop\nook> calibre-debug -e me.py source.epub --smarten_punctuation
Usage: calibre-debug.exe [options]

Various command line interfaces useful for debugging calibre. With no options,
this command starts an embedded python interpreter. You can also run the main 
calibre GUI and the calibre viewer in debug mode.

It also contains interfaces to various bits of calibre that do not have
dedicated command line tools, such as font subsetting, tweaking ebooks and so on.


Whenever you pass arguments to calibre-debug.exe that have spaces in them, 
enclose the arguments in quotation marks.
calibre-debug.exe: error: no such option: --smarten_punctuation

I'd started writing up some similar instructions for epubspllit using 'calibre-debug -e' instead of calling for a separate python instead when I found this issue. On reflection, I probably should have reported it--I know I used to use 'calibre-debug -e' to call py files and pass options.
JimmXinu is offline   Reply With Quote