Add /plugins python_version command
This commit is contained in:
@@ -65,6 +65,12 @@ _unref_module(PyObject *module)
|
||||
Py_XDECREF(module);
|
||||
}
|
||||
|
||||
const char*
|
||||
python_get_version(void)
|
||||
{
|
||||
return Py_GetVersion();
|
||||
}
|
||||
|
||||
void
|
||||
python_env_init(void)
|
||||
{
|
||||
@@ -72,9 +78,6 @@ python_env_init(void)
|
||||
|
||||
python_init_prof();
|
||||
|
||||
const char *ver = Py_GetVersion();
|
||||
cons_show("PYTHON: %s", ver);
|
||||
|
||||
gchar *plugins_dir = plugins_get_dir();
|
||||
GString *path = g_string_new("import sys\n");
|
||||
g_string_append(path, "sys.path.append(\"");
|
||||
|
||||
@@ -43,6 +43,8 @@ void python_check_error(void);
|
||||
void allow_python_threads();
|
||||
void disable_python_threads();
|
||||
|
||||
const char* python_get_version(void);
|
||||
|
||||
void python_init_hook(ProfPlugin *plugin, const char *const version, const char *const status,
|
||||
const char *const account_name, const char *const fulljid);
|
||||
void python_on_start_hook(ProfPlugin *plugin);
|
||||
|
||||
Reference in New Issue
Block a user