12-24-2008, 08:22 PM | #16 |
creator of calibre
Posts: 44,017
Karma: 22669822
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
Download zip file, open calibre config dialog. Specify path to zip file. Plugin added.
Some plugins might need configuration. Click on the plugin in the plugin list, click the customize plugin button, enter whatever customization information is needed, plugin customized. |
12-25-2008, 12:19 AM | #17 |
Zealot
Posts: 130
Karma: 96
Join Date: Aug 2008
Location: metro Atlanta, GA
Device: Sony Reader PRS-505
|
Hey - I just discovered the little tool box icon - yeah! So, now I understand how you'd do the plugins. Thanks.
|
Advert | |
|
12-25-2008, 07:10 PM | #18 |
creator of calibre
Posts: 44,017
Karma: 22669822
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
DOcumentation is at http://calibre.kovidgoyal.net/user_m...customize.html
|
12-27-2008, 09:00 PM | #19 |
Addict
Posts: 277
Karma: 1004969
Join Date: Mar 2007
Device: Sony Reader
|
Kovid,
I'm trying to get a handle on your plugins. I copied your "Hello World" script, and pasted it into a file. When I try to add it to Calibre, I get this error: invalid syntax (, line 1) Maybe I'm missing something simple, but it seems to be having an invalid syntax error on "import os". Detailed traceback: Traceback (most recent call last): File "calibre\gui2\dialogs\config.pyo", line 251, in add_plugin File "C:\Program Files\calibre\library.zip\calibre\customize\ui.py" , line 173, in add_plugin File "C:\Program Files\calibre\library.zip\calibre\customize\ui.py" , line 52, in load_plugin File "", line 1 import os ^ SyntaxError: invalid syntaxCan you give me any hints? Thanks. |
12-28-2008, 02:00 PM | #20 |
creator of calibre
Posts: 44,017
Karma: 22669822
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
Looks like an indentation error in your version of the hello world plugin. In any case wait a couple of hours, version 0.4.121 will be released its documentation includes a link to the hello world plugin as a zip file that you can test and modify directly.
|
Advert | |
|
12-28-2008, 02:09 PM | #21 |
Addict
Posts: 277
Karma: 1004969
Join Date: Mar 2007
Device: Sony Reader
|
U Da Man!
Seriously. I know you hear this a lot, but the work you've done on this application is incredible. Our devices would not be as easy/fun to use without the work you've done on Calibre. |
12-28-2008, 02:10 PM | #22 |
zeldinha zippy zeldissima
Posts: 27,827
Karma: 921169
Join Date: Dec 2007
Location: Paris, France
Device: eb1150 & is that a nook in her pocket, or she just happy to see you?
|
oh, yep. that is really true. add my appreciation in there as well ! and here's some karma while i'm at it.
|
12-28-2008, 03:28 PM | #23 |
creator of calibre
Posts: 44,017
Karma: 22669822
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
Well, I only do it 'cause it's fun, and the user community at mobileread is a big part of making it fun
|
12-28-2008, 03:32 PM | #24 |
zeldinha zippy zeldissima
Posts: 27,827
Karma: 921169
Join Date: Dec 2007
Location: Paris, France
Device: eb1150 & is that a nook in her pocket, or she just happy to see you?
|
|
12-28-2008, 04:40 PM | #25 |
Addict
Posts: 277
Karma: 1004969
Join Date: Mar 2007
Device: Sony Reader
|
Okay, I'm back with a question about the plugins.
I downloaded the helloworld_plugin.py, zipped it into my own helloworld_plugin.zip file, and it added to Calibre with no problem. When I try to edit the file (notepad, wordpad, pythonwin, word, and any other program I can find) it errors with the syntax error on "import os". What are you using to edit/build your .py files? When I view your helloworld in notepad, there aren't even any line breaks, and it works. I'm running windows Vista if that makes any difference. Thanks. |
12-28-2008, 04:59 PM | #26 |
creator of calibre
Posts: 44,017
Karma: 22669822
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
The file has unix line endings. Use a programmers editor like notepad++ (free)
|
12-28-2008, 05:01 PM | #27 |
Addict
Posts: 277
Karma: 1004969
Join Date: Mar 2007
Device: Sony Reader
|
Ah, the unix line endings explains it. I'm not all that familiar with python.
Thanks. |
12-30-2008, 10:03 PM | #28 |
idiot
Posts: 91
Karma: 16
Join Date: Nov 2008
Location: Grand Cayman
Device: Sony 505, 300, and 650
|
Are any plug ins available as stated in the first post? How would one go about finding that, or is it something that has to be created by each individual?
|
01-01-2009, 10:31 AM | #29 |
Addict
Posts: 277
Karma: 1004969
Join Date: Mar 2007
Device: Sony Reader
|
I'm trying to figure out how to build a plugin to make a call to the windows(dos) command line, so that when I add a book to calibre I can launch another application (Like Microsoft Word). however, I'm not getting any result when loading a lit file. Anyone have any thoughts? I'm not all that familiar with Python, so it's entirely possible I'm missing something.
The relevant lines I changed from Kovid's example: file_types = set(['lit']) # The file types that this plugin will be applied to on_import = True # Run this plugin after import is complete AND subprocess.call(r'C:\WINDOWS\system32\cmd.exe /C "C:\Program Files\Microsoft Office\OFFICE11\winword.exe"') OR os.system('"C:\Program Files\Microsoft Office\OFFICE11\winword.exe"') neither the subprocess.call or os.system work. Last edited by junkml; 01-01-2009 at 10:33 AM. |
01-01-2009, 01:23 PM | #30 |
creator of calibre
Posts: 44,017
Karma: 22669822
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
Use subprocess, os.system is deprecated. Try using
Code:
subprocess.call('path to program', shell=True) |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Calibre GUI behavior between machines | phenomshel | Calibre | 2 | 08-21-2010 06:28 PM |
Editing Capabilities in calibre | GJN | Calibre | 3 | 12-21-2009 05:59 PM |
Calibre 0.6.10 GUI crashes on startup | Wagenius | Calibre | 1 | 09-03-2009 01:53 AM |
Mobi2mobi GUI has died again/New version? | AlexBell | Kindle Formats | 8 | 12-10-2008 08:13 PM |
Calibre GUI crash on convert | aapezzuto | Calibre | 1 | 08-02-2008 06:39 PM |