1
0
mirror of https://github.com/profanity-im/profanity.git synced 2024-12-04 14:46:46 -05:00

Added prof_on_start function to hello world plugin

This commit is contained in:
James Booth 2013-07-25 01:17:45 +01:00
parent 4f42bb570d
commit 586ea10071
2 changed files with 8 additions and 1 deletions

7
helloworld.py Normal file
View File

@ -0,0 +1,7 @@
import prof
def prof_on_start():
helloworld()
def helloworld():
prof.cons_show("Hello world!")

View File

@ -55,7 +55,7 @@ api_init(void)
if (pModule != NULL) { if (pModule != NULL) {
pFunc = PyObject_GetAttrString(pModule, "helloworld"); pFunc = PyObject_GetAttrString(pModule, "prof_on_start");
if (pFunc == NULL) { if (pFunc == NULL) {
cons_show("NULL pfunc"); cons_show("NULL pfunc");