summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--po/POTFILES.in19
-rw-r--r--po/cs.po200
-rw-r--r--po/de.po200
-rw-r--r--po/es.po196
-rw-r--r--po/fr.po180
-rw-r--r--po/hu.po200
-rw-r--r--po/ru.po200
-rw-r--r--po/srcfiles.cmake19
-rw-r--r--po/weechat.pot131
-rw-r--r--src/plugins/scripts/lua/weechat-lua.c210
-rw-r--r--src/plugins/scripts/perl/weechat-perl.c209
-rw-r--r--src/plugins/scripts/python/weechat-python.c207
-rw-r--r--src/plugins/scripts/ruby/weechat-ruby-api.c10
-rw-r--r--src/plugins/scripts/ruby/weechat-ruby.c225
-rw-r--r--src/plugins/scripts/script.c123
-rw-r--r--src/plugins/scripts/script.h16
16 files changed, 1342 insertions, 1003 deletions
diff --git a/po/POTFILES.in b/po/POTFILES.in
index 7e759a6b4..80368b825 100644
--- a/po/POTFILES.in
+++ b/po/POTFILES.in
@@ -125,14 +125,27 @@
./src/plugins/plugin.h
./src/plugins/plugin-infolist.c
./src/plugins/plugin-infolist.h
-./src/plugins/scripts/lua/lua.c
+./src/plugins/scripts/lua/weechat-lua-api.c
+./src/plugins/scripts/lua/weechat-lua-api.h
+./src/plugins/scripts/lua/weechat-lua.c
+./src/plugins/scripts/lua/weechat-lua.h
./src/plugins/scripts/perl/weechat-perl-api.c
./src/plugins/scripts/perl/weechat-perl-api.h
./src/plugins/scripts/perl/weechat-perl.c
./src/plugins/scripts/perl/weechat-perl.h
-./src/plugins/scripts/python/python.c
-./src/plugins/scripts/ruby/ruby.c
+./src/plugins/scripts/python/weechat-python-api.c
+./src/plugins/scripts/python/weechat-python-api.h
+./src/plugins/scripts/python/weechat-python.c
+./src/plugins/scripts/python/weechat-python.h
+./src/plugins/scripts/ruby/weechat-ruby-api.c
+./src/plugins/scripts/ruby/weechat-ruby-api.h
+./src/plugins/scripts/ruby/weechat-ruby.c
+./src/plugins/scripts/ruby/weechat-ruby.h
+./src/plugins/scripts/script-api.c
+./src/plugins/scripts/script-api.h
./src/plugins/scripts/script.c
+./src/plugins/scripts/script-callback.c
+./src/plugins/scripts/script-callback.h
./src/plugins/scripts/script.h
./src/plugins/trigger/dump.c
./src/plugins/trigger/trigger.c
diff --git a/po/cs.po b/po/cs.po
index 16803a597..23ed31181 100644
--- a/po/cs.po
+++ b/po/cs.po
@@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat 0.2.7-dev\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
-"POT-Creation-Date: 2008-01-11 14:53+0100\n"
+"POT-Creation-Date: 2008-01-14 11:13+0100\n"
"PO-Revision-Date: 2007-09-06 12:44+0200\n"
"Last-Translator: Jiri Golembiovsky <golemj@gmail.com>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@@ -4095,47 +4095,35 @@ msgid "%s%s: registered script \"%s\", version %s (%s)"
msgstr ""
#, fuzzy, c-format
-msgid "%s%s: error: %s"
-msgstr "%sServer: %s%s\n"
-
-#, c-format
-msgid "%s%s: function \"%s\" must return one valid value (%d)"
-msgstr ""
+msgid "%s%s: unable to run function \"%s\""
+msgstr "Nemůžu zapsat log soubor \"%s\"\n"
#, fuzzy, c-format
-msgid "%s%s: function \"%s\" is internally misused"
-msgstr "%s plugin \"%s\" nenalezen\n"
+msgid "%s%s: error: %s"
+msgstr "%sServer: %s%s\n"
#, fuzzy, c-format
-msgid "%s%s: not enough memory in function \"%s\""
-msgstr "%s nedostatek paměti pro nové DCC\n"
+msgid "%s%s: script \"%s\" not found"
+msgstr "%s server \"%s\" nenalezen\n"
#, fuzzy, c-format
-msgid "%s%s: loading Perl script \"%s\""
+msgid "%s%s: loading script \"%s\""
msgstr "sezeni: načítám server \"%s\"\n"
#, fuzzy, c-format
-msgid "%s%s: script \"%s\" not found"
-msgstr "%s server \"%s\" nenalezen\n"
-
-#, fuzzy, c-format
msgid "%s%s: unable to create new sub-interpreter"
msgstr "%s nemohu vytvořit server\n"
#, fuzzy, c-format
-msgid "%s%s: not enough memory to parse file \"%s\""
-msgstr "%s nedostatek paměti pro nové DCC\n"
+msgid "%s%s: unable to redirect stdout and stderr"
+msgstr "%s nemohu vytvořit server\n"
#, fuzzy, c-format
-msgid "%s%s: unable to parse file \"%s\""
+msgid "%s%s: unable to load file \"%s\""
msgstr "Nemůžu zapsat log soubor \"%s\"\n"
#, fuzzy, c-format
-msgid "%s%s: unable to run file \"%s\""
-msgstr "Nemůžu zapsat log soubor \"%s\"\n"
-
-#, fuzzy, c-format
-msgid "%s%s: unknown error while loading file \"%s\""
+msgid "%s%s: unable to execute file \"%s\""
msgstr "Nemůžu zapsat log soubor \"%s\"\n"
#, fuzzy, c-format
@@ -4156,36 +4144,123 @@ msgstr "Plugin \"%s\" odebrán.\n"
msgid "%s%s: script \"%s\" not loaded"
msgstr "%s server \"%s\" nenalezen\n"
-msgid "Registered Perl scripts:"
-msgstr ""
+#, fuzzy, c-format
+msgid "%s%s: unknown option for command \"%s\""
+msgstr "%s neznámá volba pro příkaz \"%s\"\n"
#, c-format
-msgid " %s v%s (%s), by %s, license %s"
+msgid "%s%s: function \"%s\" must return one valid value (%d)"
msgstr ""
#, fuzzy, c-format
-msgid "%s%s: unknown option for command \"%s\""
-msgstr "%s neznámá volba pro příkaz \"%s\"\n"
+msgid "%s%s: function \"%s\" is internally misused"
+msgstr "%s plugin \"%s\" nenalezen\n"
+
+#, fuzzy, c-format
+msgid "%s%s: not enough memory in function \"%s\""
+msgstr "%s nedostatek paměti pro nové DCC\n"
+
+#, fuzzy, c-format
+msgid "%s%s: not enough memory to parse file \"%s\""
+msgstr "%s nedostatek paměti pro nové DCC\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to parse file \"%s\""
+msgstr "Nemůžu zapsat log soubor \"%s\"\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to run file \"%s\""
+msgstr "Nemůžu zapsat log soubor \"%s\"\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unknown error while loading file \"%s\""
+msgstr "Nemůžu zapsat log soubor \"%s\"\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to initialize %s"
+msgstr "%s nemohu načíst plugin \"%s\"\n"
+
+#, fuzzy, c-format
+msgid "%s%s unable to run function \"%s\""
+msgstr "Nemůžu zapsat log soubor \"%s\"\n"
+
+#, fuzzy, c-format
+msgid "%s%s: function \"%s\" must return a valid value"
+msgstr "%s plugin \"%s\" nenalezen\n"
+
+#, c-format
+msgid "%s: stdout/stderr: %s%s"
+msgstr ""
#, fuzzy, c-format
-msgid "%s%s: unable to initialize Perl"
+msgid "%s%s: unable to initialize WeeChat module"
msgstr "%s nemohu načíst plugin \"%s\"\n"
+#, fuzzy, c-format
+msgid "%s%s: unable to redirect stdout"
+msgstr "Nemůžu zapsat log soubor \"%s\"\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to redirect stderr"
+msgstr "%s nemohu vytvořit server\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to launch global interpreter"
+msgstr "%s nemohu vytvořit server\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to get current interpreter state"
+msgstr "%s nemohu vytvořit server\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to free interpreter"
+msgstr "%s nemohu vytvořit server\n"
+
+#, fuzzy, c-format
+msgid "%s%s: error: \"%s\""
+msgstr "%sServer: %s%s\n"
+
+#, fuzzy, c-format
+msgid "%s%s: stdout/stderr: %s%s"
+msgstr "%sServer: %s%s\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to read file \"%s\""
+msgstr "Nemůžu zapsat log soubor \"%s\"\n"
+
+#, fuzzy, c-format
+msgid "%s%s: error while loading file \"%s\""
+msgstr "Nemůžu zapsat log soubor \"%s\"\n"
+
+#, fuzzy, c-format
+msgid "%s%s: function \"weechat_init\" is missing in file \"%s\""
+msgstr "Nemůžu zapsat log soubor \"%s\"\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to eval function \"weechat_init\" in file \"%s\""
+msgstr "Nemůžu zapsat log soubor \"%s\"\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to eval WeeChat ruby internal code"
+msgstr "%s nemohu vytvořit server\n"
+
#, fuzzy
-msgid "list/load/unload Perl scripts"
+msgid "list/load/unload scripts"
msgstr "seznam/načíst/odebrat pluginy"
#, fuzzy
-msgid "[load filename] | [autoload] | [reload] | [unload [script]]"
+msgid ""
+"[list [name]] | [listfull [name]] [load filename] | [autoload] | [reload] | "
+"[unload [name]]"
msgstr ""
"[list [jméno]] | [listfull [jméno]] | [load jméno_souboru] | [autoload] | "
"[reload [name]] | [unload [name]]"
msgid ""
-"filename: Perl script (file) to load\n"
-"script: script name to unload\n"
+"filename: script (file) to load\n"
+"name: a script name\n"
"\n"
-"Without argument, /perl command lists all loaded Perl scripts."
+"Without argument, this command lists all loaded scripts."
msgstr ""
#, c-format
@@ -4202,6 +4277,23 @@ msgstr ""
msgid "%s: error loading script \"%s\" (not enough memory)"
msgstr "%s nemohu načíst plugin \"%s\" (nedostatek paměti)\n"
+#. TRANSLATORS: %s is language (for example "perl")
+#, fuzzy, c-format
+msgid "%s scripts loaded:"
+msgstr "FIFO roura zavřena\n"
+
+#, fuzzy, c-format
+msgid " file: %s"
+msgstr " IRC(%s)\n"
+
+#, c-format
+msgid " written by \"%s\", license: %s"
+msgstr ""
+
+#, fuzzy
+msgid " (none)"
+msgstr "(neznámý)"
+
#, c-format
msgid "%s%s: unable to call function \"%s\", script is not initialized"
msgstr ""
@@ -4211,8 +4303,42 @@ msgid "%s%s: wrong arguments for function \"%s\""
msgstr "%s špatné parametry pro příkaz \"%s\"\n"
#, fuzzy
-#~ msgid "%s%s: scripts unloaded"
-#~ msgstr "FIFO roura zavřena\n"
+#~ msgid " %s%s%s v%s - %s"
+#~ msgstr " od %s%s %s(%s%s%s)"
+
+#, fuzzy
+#~ msgid ""
+#~ "[list [name]] | [listfull [name]] [load filename] | [autoload] | [reload] "
+#~ "| [unload [script]]"
+#~ msgstr ""
+#~ "[list [jméno]] | [listfull [jméno]] | [load jméno_souboru] | [autoload] | "
+#~ "[reload [name]] | [unload [name]]"
+
+#, fuzzy
+#~ msgid "%s%s: not enough memory for function \"%s\""
+#~ msgstr "%s nedostatek paměti pro nové DCC\n"
+
+#, fuzzy
+#~ msgid "[load filename] | [autoload] | [reload] | [unload [script]]"
+#~ msgstr ""
+#~ "[list [jméno]] | [listfull [jméno]] | [load jméno_souboru] | [autoload] | "
+#~ "[reload [name]] | [unload [name]]"
+
+#, fuzzy
+#~ msgid "list/load/unload Perl scripts"
+#~ msgstr "seznam/načíst/odebrat pluginy"
+
+#, fuzzy
+#~ msgid "list/load/unload Python scripts"
+#~ msgstr "seznam/načíst/odebrat pluginy"
+
+#, fuzzy
+#~ msgid "list/load/unload Ruby scripts"
+#~ msgstr "seznam/načíst/odebrat pluginy"
+
+#, fuzzy
+#~ msgid "%s%s: loading Perl script \"%s\""
+#~ msgstr "sezeni: načítám server \"%s\"\n"
#, fuzzy
#~ msgid "%s%s: plugin ended"
diff --git a/po/de.po b/po/de.po
index 80a42ccc2..737f92b43 100644
--- a/po/de.po
+++ b/po/de.po
@@ -9,7 +9,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat 0.2.7-dev\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
-"POT-Creation-Date: 2008-01-11 14:53+0100\n"
+"POT-Creation-Date: 2008-01-14 11:13+0100\n"
"PO-Revision-Date: 2007-09-06 12:44+0200\n"
"Last-Translator: Thomas Schuetz <i18n@internet-villa.de>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@@ -4092,47 +4092,35 @@ msgid "%s%s: registered script \"%s\", version %s (%s)"
msgstr ""
#, fuzzy, c-format
-msgid "%s%s: error: %s"
-msgstr "%sServer: %s%s\n"
-
-#, c-format
-msgid "%s%s: function \"%s\" must return one valid value (%d)"
-msgstr ""
+msgid "%s%s: unable to run function \"%s\""
+msgstr "Kann das Logfile nicht schreiben\n"
#, fuzzy, c-format
-msgid "%s%s: function \"%s\" is internally misused"
-msgstr "%s Plugin \"%s\" nicht gefunden\n"
+msgid "%s%s: error: %s"
+msgstr "%sServer: %s%s\n"
#, fuzzy, c-format
-msgid "%s%s: not enough memory in function \"%s\""
-msgstr "%s nicht genug Speicher für neuen DCC\n"
+msgid "%s%s: script \"%s\" not found"
+msgstr "%s Server \"%s\" nicht gefunden\n"
#, fuzzy, c-format
-msgid "%s%s: loading Perl script \"%s\""
+msgid "%s%s: loading script \"%s\""
msgstr "Sitzung: Lade Server \"%s\"\n"
#, fuzzy, c-format
-msgid "%s%s: script \"%s\" not found"
-msgstr "%s Server \"%s\" nicht gefunden\n"
-
-#, fuzzy, c-format
msgid "%s%s: unable to create new sub-interpreter"
msgstr "%s kann den Server nicht anlegen\n"
#, fuzzy, c-format
-msgid "%s%s: not enough memory to parse file \"%s\""
-msgstr "%s nicht genug Speicher für neuen DCC\n"
+msgid "%s%s: unable to redirect stdout and stderr"
+msgstr "%s kann den Server nicht anlegen\n"
#, fuzzy, c-format
-msgid "%s%s: unable to parse file \"%s\""
+msgid "%s%s: unable to load file \"%s\""
msgstr "Kann das Logfile nicht schreiben\n"
#, fuzzy, c-format
-msgid "%s%s: unable to run file \"%s\""
-msgstr "Kann das Logfile nicht schreiben\n"
-
-#, fuzzy, c-format
-msgid "%s%s: unknown error while loading file \"%s\""
+msgid "%s%s: unable to execute file \"%s\""
msgstr "Kann das Logfile nicht schreiben\n"
#, fuzzy, c-format
@@ -4153,36 +4141,123 @@ msgstr "Plugin \"%s\" entladen.\n"
msgid "%s%s: script \"%s\" not loaded"
msgstr "%s Server \"%s\" nicht gefunden\n"
-msgid "Registered Perl scripts:"
-msgstr ""
+#, fuzzy, c-format
+msgid "%s%s: unknown option for command \"%s\""
+msgstr "%s unbekannte Option für den \"%s\"-Befehl\n"
#, c-format
-msgid " %s v%s (%s), by %s, license %s"
+msgid "%s%s: function \"%s\" must return one valid value (%d)"
msgstr ""
#, fuzzy, c-format
-msgid "%s%s: unknown option for command \"%s\""
-msgstr "%s unbekannte Option für den \"%s\"-Befehl\n"
+msgid "%s%s: function \"%s\" is internally misused"
+msgstr "%s Plugin \"%s\" nicht gefunden\n"
+
+#, fuzzy, c-format
+msgid "%s%s: not enough memory in function \"%s\""
+msgstr "%s nicht genug Speicher für neuen DCC\n"
+
+#, fuzzy, c-format
+msgid "%s%s: not enough memory to parse file \"%s\""
+msgstr "%s nicht genug Speicher für neuen DCC\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to parse file \"%s\""
+msgstr "Kann das Logfile nicht schreiben\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to run file \"%s\""
+msgstr "Kann das Logfile nicht schreiben\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unknown error while loading file \"%s\""
+msgstr "Kann das Logfile nicht schreiben\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to initialize %s"
+msgstr "%s kann das Plugin \"%s\" nicht initialisieren\n"
+
+#, fuzzy, c-format
+msgid "%s%s unable to run function \"%s\""
+msgstr "Kann das Logfile nicht schreiben\n"
+
+#, fuzzy, c-format
+msgid "%s%s: function \"%s\" must return a valid value"
+msgstr "%s Plugin \"%s\" nicht gefunden\n"
+
+#, c-format
+msgid "%s: stdout/stderr: %s%s"
+msgstr ""
#, fuzzy, c-format
-msgid "%s%s: unable to initialize Perl"
+msgid "%s%s: unable to initialize WeeChat module"
msgstr "%s kann das Plugin \"%s\" nicht initialisieren\n"
+#, fuzzy, c-format
+msgid "%s%s: unable to redirect stdout"
+msgstr "Kann das Logfile nicht schreiben\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to redirect stderr"
+msgstr "%s kann den Server nicht anlegen\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to launch global interpreter"
+msgstr "%s kann den Server nicht anlegen\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to get current interpreter state"
+msgstr "%s kann den Server nicht anlegen\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to free interpreter"
+msgstr "%s kann den Server nicht anlegen\n"
+
+#, fuzzy, c-format
+msgid "%s%s: error: \"%s\""
+msgstr "%sServer: %s%s\n"
+
+#, fuzzy, c-format
+msgid "%s%s: stdout/stderr: %s%s"
+msgstr "%sServer: %s%s\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to read file \"%s\""
+msgstr "Kann das Logfile nicht schreiben\n"
+
+#, fuzzy, c-format
+msgid "%s%s: error while loading file \"%s\""
+msgstr "Kann das Logfile nicht schreiben\n"
+
+#, fuzzy, c-format
+msgid "%s%s: function \"weechat_init\" is missing in file \"%s\""
+msgstr "Kann das Logfile nicht schreiben\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to eval function \"weechat_init\" in file \"%s\""
+msgstr "Kann das Logfile nicht schreiben\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to eval WeeChat ruby internal code"
+msgstr "%s kann den Server nicht anlegen\n"
+
#, fuzzy
-msgid "list/load/unload Perl scripts"
+msgid "list/load/unload scripts"
msgstr "auflisten/laden/entladen von Plugins"
#, fuzzy
-msgid "[load filename] | [autoload] | [reload] | [unload [script]]"
+msgid ""
+"[list [name]] | [listfull [name]] [load filename] | [autoload] | [reload] | "
+"[unload [name]]"
msgstr ""
"[list [Name]] | [listfull [Name]] | [load Dateiname] | [autoload] | [reload "
"[Name]] | [unload [Name]]"
msgid ""
-"filename: Perl script (file) to load\n"
-"script: script name to unload\n"
+"filename: script (file) to load\n"
+"name: a script name\n"
"\n"
-"Without argument, /perl command lists all loaded Perl scripts."
+"Without argument, this command lists all loaded scripts."
msgstr ""
#, c-format
@@ -4199,6 +4274,23 @@ msgstr ""
msgid "%s: error loading script \"%s\" (not enough memory)"
msgstr "%s kann das Plugin \"%s\" nicht laden (Speichermangel)\n"
+#. TRANSLATORS: %s is language (for example "perl")
+#, fuzzy, c-format
+msgid "%s scripts loaded:"
+msgstr "FIFO geschlossen\n"
+
+#, fuzzy, c-format
+msgid " file: %s"
+msgstr " IRC(%s)\n"
+
+#, c-format
+msgid " written by \"%s\", license: %s"
+msgstr ""
+
+#, fuzzy
+msgid " (none)"
+msgstr "(unbekannt)"
+
#, c-format
msgid "%s%s: unable to call function \"%s\", script is not initialized"
msgstr ""
@@ -4208,8 +4300,42 @@ msgid "%s%s: wrong arguments for function \"%s\""
msgstr "%s fehlerhafte Argumente für der \"%s\"-Befehl\n"
#, fuzzy
-#~ msgid "%s%s: scripts unloaded"
-#~ msgstr "FIFO geschlossen\n"
+#~ msgid " %s%s%s v%s - %s"
+#~ msgstr " durch %s%s %s(%s%s%s)"
+
+#, fuzzy
+#~ msgid ""
+#~ "[list [name]] | [listfull [name]] [load filename] | [autoload] | [reload] "
+#~ "| [unload [script]]"
+#~ msgstr ""
+#~ "[list [Name]] | [listfull [Name]] | [load Dateiname] | [autoload] | "
+#~ "[reload [Name]] | [unload [Name]]"
+
+#, fuzzy
+#~ msgid "%s%s: not enough memory for function \"%s\""
+#~ msgstr "%s nicht genug Speicher für neuen DCC\n"
+
+#, fuzzy
+#~ msgid "[load filename] | [autoload] | [reload] | [unload [script]]"
+#~ msgstr ""
+#~ "[list [Name]] | [listfull [Name]] | [load Dateiname] | [autoload] | "
+#~ "[reload [Name]] | [unload [Name]]"
+
+#, fuzzy
+#~ msgid "list/load/unload Perl scripts"
+#~ msgstr "auflisten/laden/entladen von Plugins"
+
+#, fuzzy
+#~ msgid "list/load/unload Python scripts"
+#~ msgstr "auflisten/laden/entladen von Plugins"
+
+#, fuzzy
+#~ msgid "list/load/unload Ruby scripts"
+#~ msgstr "auflisten/laden/entladen von Plugins"
+
+#, fuzzy
+#~ msgid "%s%s: loading Perl script \"%s\""
+#~ msgstr "Sitzung: Lade Server \"%s\"\n"
#, fuzzy
#~ msgid "%s%s: plugin ended"
diff --git a/po/es.po b/po/es.po
index 6384eda6f..a984c8a2f 100644
--- a/po/es.po
+++ b/po/es.po
@@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat 0.2.7-dev\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
-"POT-Creation-Date: 2008-01-11 14:53+0100\n"
+"POT-Creation-Date: 2008-01-14 11:13+0100\n"
"PO-Revision-Date: 2007-09-19 12:09+0200\n"
"Last-Translator: Roberto González Cardenete <robert.glez@gmail.com>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@@ -4106,47 +4106,35 @@ msgid "%s%s: registered script \"%s\", version %s (%s)"
msgstr ""
#, fuzzy, c-format
-msgid "%s%s: error: %s"
-msgstr "%sServidor: %s%s\n"
-
-#, c-format
-msgid "%s%s: function \"%s\" must return one valid value (%d)"
-msgstr ""
+msgid "%s%s: unable to run function \"%s\""
+msgstr "No es posible escribir un fichero de log para un búfer\n"
#, fuzzy, c-format
-msgid "%s%s: function \"%s\" is internally misused"
-msgstr "%s plugin \"%s\" no encontrado\n"
+msgid "%s%s: error: %s"
+msgstr "%sServidor: %s%s\n"
#, fuzzy, c-format
-msgid "%s%s: not enough memory in function \"%s\""
-msgstr "%s no hay memoria suficiente para un nuevo DCC\n"
+msgid "%s%s: script \"%s\" not found"
+msgstr "%s servidor \"%s\" no encontrado\n"
#, fuzzy, c-format
-msgid "%s%s: loading Perl script \"%s\""
+msgid "%s%s: loading script \"%s\""
msgstr "sesión: cargando servidor \"%s\"\n"
#, fuzzy, c-format
-msgid "%s%s: script \"%s\" not found"
-msgstr "%s servidor \"%s\" no encontrado\n"
-
-#, fuzzy, c-format
msgid "%s%s: unable to create new sub-interpreter"
msgstr "%s no es posible crear el servidor\n"
#, fuzzy, c-format
-msgid "%s%s: not enough memory to parse file \"%s\""
-msgstr "%s no hay memoria suficiente para un nuevo DCC\n"
+msgid "%s%s: unable to redirect stdout and stderr"
+msgstr "%s no es posible crear el servidor\n"
#, fuzzy, c-format
-msgid "%s%s: unable to parse file \"%s\""
+msgid "%s%s: unable to load file \"%s\""
msgstr "No es posible escribir un fichero de log para un búfer\n"
#, fuzzy, c-format
-msgid "%s%s: unable to run file \"%s\""
-msgstr "No es posible escribir un fichero de log para un búfer\n"
-
-#, fuzzy, c-format
-msgid "%s%s: unknown error while loading file \"%s\""
+msgid "%s%s: unable to execute file \"%s\""
msgstr "No es posible escribir un fichero de log para un búfer\n"
#, fuzzy, c-format
@@ -4167,34 +4155,121 @@ msgstr "Plugin \"%s\" descargado.\n"
msgid "%s%s: script \"%s\" not loaded"
msgstr "%s servidor \"%s\" no encontrado\n"
-msgid "Registered Perl scripts:"
-msgstr ""
+#, fuzzy, c-format
+msgid "%s%s: unknown option for command \"%s\""
+msgstr "%s opción desconocida para el comando \"%s\"\n"
#, c-format
-msgid " %s v%s (%s), by %s, license %s"
+msgid "%s%s: function \"%s\" must return one valid value (%d)"
msgstr ""
#, fuzzy, c-format
-msgid "%s%s: unknown option for command \"%s\""
-msgstr "%s opción desconocida para el comando \"%s\"\n"
+msgid "%s%s: function \"%s\" is internally misused"
+msgstr "%s plugin \"%s\" no encontrado\n"
+
+#, fuzzy, c-format
+msgid "%s%s: not enough memory in function \"%s\""
+msgstr "%s no hay memoria suficiente para un nuevo DCC\n"
+
+#, fuzzy, c-format
+msgid "%s%s: not enough memory to parse file \"%s\""
+msgstr "%s no hay memoria suficiente para un nuevo DCC\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to parse file \"%s\""
+msgstr "No es posible escribir un fichero de log para un búfer\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to run file \"%s\""
+msgstr "No es posible escribir un fichero de log para un búfer\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unknown error while loading file \"%s\""
+msgstr "No es posible escribir un fichero de log para un búfer\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to initialize %s"
+msgstr "%s no ha sido posible inicializar el plugin \"%s\"\n"
+
+#, fuzzy, c-format
+msgid "%s%s unable to run function \"%s\""
+msgstr "No es posible escribir un fichero de log para un búfer\n"
+
+#, fuzzy, c-format
+msgid "%s%s: function \"%s\" must return a valid value"
+msgstr "%s plugin \"%s\" no encontrado\n"
+
+#, c-format
+msgid "%s: stdout/stderr: %s%s"
+msgstr ""
#, fuzzy, c-format
-msgid "%s%s: unable to initialize Perl"
+msgid "%s%s: unable to initialize WeeChat module"
msgstr "%s no ha sido posible inicializar el plugin \"%s\"\n"
+#, fuzzy, c-format
+msgid "%s%s: unable to redirect stdout"
+msgstr "No es posible escribir un fichero de log para un búfer\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to redirect stderr"
+msgstr "%s no es posible crear el servidor\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to launch global interpreter"
+msgstr "%s no es posible crear el servidor\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to get current interpreter state"
+msgstr "%s no es posible crear el servidor\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to free interpreter"
+msgstr "%s no es posible crear el servidor\n"
+
+#, fuzzy, c-format
+msgid "%s%s: error: \"%s\""
+msgstr "%sServidor: %s%s\n"
+
+#, fuzzy, c-format
+msgid "%s%s: stdout/stderr: %s%s"
+msgstr "%sServidor: %s%s\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to read file \"%s\""
+msgstr "No es posible escribir un fichero de log para un búfer\n"
+
+#, fuzzy, c-format
+msgid "%s%s: error while loading file \"%s\""
+msgstr "No es posible escribir un fichero de log para un búfer\n"
+
+#, fuzzy, c-format
+msgid "%s%s: function \"weechat_init\" is missing in file \"%s\""
+msgstr "No es posible escribir un fichero de log para un búfer\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to eval function \"weechat_init\" in file \"%s\""
+msgstr "No es posible escribir un fichero de log para un búfer\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to eval WeeChat ruby internal code"
+msgstr "%s no es posible crear el servidor\n"
+
#, fuzzy
-msgid "list/load/unload Perl scripts"
+msgid "list/load/unload scripts"
msgstr "listar/cargar/descargar plugins"
#, fuzzy
-msgid "[load filename] | [autoload] | [reload] | [unload [script]]"
+msgid ""
+"[list [name]] | [listfull [name]] [load filename] | [autoload] | [reload] | "
+"[unload [name]]"
msgstr "[cargar fichero] | [autocargar] | [recargar] | [descargar]"
msgid ""
-"filename: Perl script (file) to load\n"
-"script: script name to unload\n"
+"filename: script (file) to load\n"
+"name: a script name\n"
"\n"
-"Without argument, /perl command lists all loaded Perl scripts."
+"Without argument, this command lists all loaded scripts."
msgstr ""
#, c-format
@@ -4212,6 +4287,23 @@ msgid "%s: error loading script \"%s\" (not enough memory)"
msgstr ""
"%s no ha sido posible cargar el plugin \"%s\" (no hay suficiente memoria)\n"
+#. TRANSLATORS: %s is language (for example "perl")
+#, fuzzy, c-format
+msgid "%s scripts loaded:"
+msgstr "La tubería FIFO está cerrada\n"
+
+#, fuzzy, c-format
+msgid " file: %s"
+msgstr " IRC(%s)\n"
+
+#, c-format
+msgid " written by \"%s\", license: %s"
+msgstr ""
+
+#, fuzzy
+msgid " (none)"
+msgstr "(desconocido)"
+
#, c-format
msgid "%s%s: unable to call function \"%s\", script is not initialized"
msgstr ""
@@ -4221,8 +4313,38 @@ msgid "%s%s: wrong arguments for function \"%s\""
msgstr "%s argumentos incorrectos para el comando \"%s\"\n"
#, fuzzy
-#~ msgid "%s%s: scripts unloaded"
-#~ msgstr "La tubería FIFO está cerrada\n"
+#~ msgid " %s%s%s v%s - %s"
+#~ msgstr "%s%s %s(%s%s%s)%s ha salido"
+
+#, fuzzy
+#~ msgid ""
+#~ "[list [name]] | [listfull [name]] [load filename] | [autoload] | [reload] "
+#~ "| [unload [script]]"
+#~ msgstr "[cargar fichero] | [autocargar] | [recargar] | [descargar]"
+
+#, fuzzy
+#~ msgid "%s%s: not enough memory for function \"%s\""
+#~ msgstr "%s no hay memoria suficiente para un nuevo DCC\n"
+
+#, fuzzy
+#~ msgid "[load filename] | [autoload] | [reload] | [unload [script]]"
+#~ msgstr "[cargar fichero] | [autocargar] | [recargar] | [descargar]"
+
+#, fuzzy
+#~ msgid "list/load/unload Perl scripts"
+#~ msgstr "listar/cargar/descargar plugins"
+
+#, fuzzy
+#~ msgid "list/load/unload Python scripts"
+#~ msgstr "listar/cargar/descargar plugins"
+
+#, fuzzy
+#~ msgid "list/load/unload Ruby scripts"
+#~ msgstr "listar/cargar/descargar plugins"
+
+#, fuzzy
+#~ msgid "%s%s: loading Perl script \"%s\""
+#~ msgstr "sesión: cargando servidor \"%s\"\n"
#, fuzzy
#~ msgid "%s%s: plugin ended"
diff --git a/po/fr.po b/po/fr.po
index e86808f67..511536609 100644
--- a/po/fr.po
+++ b/po/fr.po
@@ -6,8 +6,8 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat 0.2.7-dev\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
-"POT-Creation-Date: 2008-01-11 14:53+0100\n"
-"PO-Revision-Date: 2008-01-11 14:55+0100\n"
+"POT-Creation-Date: 2008-01-14 11:13+0100\n"
+"PO-Revision-Date: 2008-01-14 11:15+0100\n"
"Last-Translator: FlashCode <flashcode@flashtux.org>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
"MIME-Version: 1.0\n"
@@ -4017,32 +4017,69 @@ msgid "%s%s: registered script \"%s\", version %s (%s)"
msgstr "%s%s: script \"%s\" chargé, version %s (%s)"
#, c-format
+msgid "%s%s: unable to run function \"%s\""
+msgstr "%s%s: impossible de lancer la fonction \"%s\""
+
+#, c-format
msgid "%s%s: error: %s"
msgstr "%s%s: erreur: %s"
#, c-format
-msgid "%s%s: function \"%s\" must return one valid value (%d)"
-msgstr "%s%s: la fonction \"%s\" doit retourner une valeur valide (%d)"
+msgid "%s%s: script \"%s\" not found"
+msgstr "%s%s: script \"%s\" non trouvé"
#, c-format
-msgid "%s%s: function \"%s\" is internally misused"
-msgstr "%s%s: la fonction \"%s\" est mal utilisée en interne"
+msgid "%s%s: loading script \"%s\""
+msgstr "%s%s: chargement du script \"%s\""
#, c-format
-msgid "%s%s: not enough memory in function \"%s\""
-msgstr "%s%s: pas assez de mémoire dans la fonction \"%s\""
+msgid "%s%s: unable to create new sub-interpreter"
+msgstr "%s%s: impossible de créer le sous-interpréteur"
#, c-format
-msgid "%s%s: loading Perl script \"%s\""
-msgstr "%s%s: chargement du script Perl \"%s\""
+msgid "%s%s: unable to redirect stdout and stderr"
+msgstr "%s%s: impossible de rediriger stdout et stderr"
#, c-format
-msgid "%s%s: script \"%s\" not found"
-msgstr "%s%s: script \"%s\" non trouvé"
+msgid "%s%s: unable to load file \"%s\""
+msgstr "%s%s: impossible de charger le fichier \"%s\""
#, c-format
-msgid "%s%s: unable to create new sub-interpreter"
-msgstr "%s%s: impossible de créer le sous-interpréteur"
+msgid "%s%s: unable to execute file \"%s\""
+msgstr "%s%s: impossible d'exécuter le fichier \"%s\""
+
+#, c-format
+msgid "%s%s: function \"register\" not found (or failed) in file \"%s\""
+msgstr ""
+"%s%s: fonction \"register\" non trouvée (ou a échoué) dans le fichier \"%s\""
+
+#, c-format
+msgid "%s%s: unloading script \"%s\""
+msgstr "%s%s: déchargement du script \"%s\""
+
+#, c-format
+msgid "%s%s: script \"%s\" unloaded"
+msgstr "%s%s: script \"%s\" déchargé"
+
+#, c-format
+msgid "%s%s: script \"%s\" not loaded"
+msgstr "%s%s: script \"%s\" non chargé"
+
+#, c-format
+msgid "%s%s: unknown option for command \"%s\""
+msgstr "%s%s: option inconnue pour la commande \"%s\""
+
+#, c-format
+msgid "%s%s: function \"%s\" must return one valid value (%d)"
+msgstr "%s%s: la fonction \"%s\" doit retourner une valeur valide (%d)"
+
+#, c-format
+msgid "%s%s: function \"%s\" is internally misused"
+msgstr "%s%s: la fonction \"%s\" est mal utilisée en interne"
+
+#, c-format
+msgid "%s%s: not enough memory in function \"%s\""
+msgstr "%s%s: pas assez de mémoire dans la fonction \"%s\""
#, c-format
msgid "%s%s: not enough memory to parse file \"%s\""
@@ -4058,56 +4095,99 @@ msgstr "%s%s: impossible de lancer le fichier \"%s\""
#, c-format
msgid "%s%s: unknown error while loading file \"%s\""
-msgstr "%s%s: erreur inconnue en chargeant le fichier \"%s\""
+msgstr "%s%s: erreur inconnue en chargement du fichier \"%s\""
#, c-format
-msgid "%s%s: function \"register\" not found (or failed) in file \"%s\""
-msgstr ""
-"%s%s: fonction \"register\" non trouvée (ou a échoué) dans le fichier \"%s\""
+msgid "%s%s: unable to initialize %s"
+msgstr "%s%s: impossible d'initialiser %s"
#, c-format
-msgid "%s%s: unloading script \"%s\""
-msgstr "%s%s: déchargement du script \"%s\""
+msgid "%s%s unable to run function \"%s\""
+msgstr "%s%s: impossible de lancer la fonction \"%s\""
#, c-format
-msgid "%s%s: script \"%s\" unloaded"
-msgstr "%s%s: script \"%s\" déchargé"
+msgid "%s%s: function \"%s\" must return a valid value"
+msgstr "%s%s: la fonction \"%s\" doit retourner une valeur valide"
#, c-format
-msgid "%s%s: script \"%s\" not loaded"
-msgstr "%s%s: script \"%s\" non chargé"
+msgid "%s: stdout/stderr: %s%s"
+msgstr "%s: stdout/stderr: %s%s"
-msgid "Registered Perl scripts:"
-msgstr "Scripts Perl chargés:"
+#, c-format
+msgid "%s%s: unable to initialize WeeChat module"
+msgstr "%s%s: impossible d'initialiser le module WeeChat"
#, c-format
-msgid " %s v%s (%s), by %s, license %s"
-msgstr " %s v%s (%s), par %s, licence %s"
+msgid "%s%s: unable to redirect stdout"
+msgstr "%s%s: impossible de rediriger stdout"
#, c-format
-msgid "%s%s: unknown option for command \"%s\""
-msgstr "%s%s: option inconnue pour la commande \"%s\""
+msgid "%s%s: unable to redirect stderr"
+msgstr "%s%s: impossible de rediriger stderr"
#, c-format
-msgid "%s%s: unable to initialize Perl"
-msgstr "%s%s: impossible d'initialiser Perl"
+msgid "%s%s: unable to launch global interpreter"
+msgstr "%s%s: impossible de lancer l'interpréteur global"
-msgid "list/load/unload Perl scripts"
-msgstr "liste/charge/décharge des scripts Perl"
+#, c-format
+msgid "%s%s: unable to get current interpreter state"
+msgstr "%s%s: impossible de lire l'état courant de l'interpréteur"
-msgid "[load filename] | [autoload] | [reload] | [unload [script]]"
-msgstr "[load fichier] | [autoload] | [reload] | [unload [script]]"
+#, c-format
+msgid "%s%s: unable to free interpreter"
+msgstr "%s%s: impossible de libérer l'interpréteur"
+
+#, c-format
+msgid "%s%s: error: \"%s\""
+msgstr "%s%s: erreur: \"%s\""
+
+#, c-format
+msgid "%s%s: stdout/stderr: %s%s"
+msgstr "%s%s: stdout/stderr: %s%s"
+
+#, c-format
+msgid "%s%s: unable to read file \"%s\""
+msgstr "%s%s: impossible de lire le fichier \"%s\""
+
+#, c-format
+msgid "%s%s: error while loading file \"%s\""
+msgstr "%s%s: erreur en chargement du fichier \"%s\""
+
+#, c-format
+msgid "%s%s: function \"weechat_init\" is missing in file \"%s\""
+msgstr ""
+"%s%s: la fonction \"weechat_init\" est manquante dans le fichier \"%s\""
+
+#, c-format
+msgid "%s%s: unable to eval function \"weechat_init\" in file \"%s\""
+msgstr ""
+"%s%s: impossible d'évaluer la fonction \"weechat_init\" dans le fichier \"%s"
+"\""
+
+#, c-format
+msgid "%s%s: unable to eval WeeChat ruby internal code"
+msgstr "%s%s: impossible d'évaluer le code ruby interne WeeChat"
+
+msgid "list/load/unload scripts"
+msgstr "liste/charge/décharge des scripts"
+
+msgid ""
+"[list [name]] | [listfull [name]] [load filename] | [autoload] | [reload] | "
+"[unload [name]]"
+msgstr ""
+"[list [nom]] | [listfull [nom]] | [load fichier] | [autoload] | [reload] | "
+"[unload [nom]]"
msgid ""
-"filename: Perl script (file) to load\n"
-"script: script name to unload\n"
+"filename: script (file) to load\n"
+"name: a script name\n"
"\n"
-"Without argument, /perl command lists all loaded Perl scripts."
+"Without argument, this command lists all loaded scripts."
msgstr ""
-"fichier: script Perl (fichier) à charger\n"
-"script: nom du script à décharger\n"
+"fichier: script (fichier) à charger\n"
+"nom: un nom de script\n"
"\n"
-"Sans argument, la commande /perl liste tous les scripts Perl chargés."
+"Sans argument, cette commande liste tous les scripts chargés."
#, c-format
msgid "%s: error loading script \"%s\" (bad name, spaces are forbidden)"
@@ -4127,6 +4207,22 @@ msgstr ""
msgid "%s: error loading script \"%s\" (not enough memory)"
msgstr "%s: erreur de chargement du script \"%s\" (mémoire insuffisante)"
+#. TRANSLATORS: %s is language (for example "perl")
+#, c-format
+msgid "%s scripts loaded:"
+msgstr "Scripts %s chargés:"
+
+#, c-format
+msgid " file: %s"
+msgstr " fichier: %s"
+
+#, c-format
+msgid " written by \"%s\", license: %s"
+msgstr " écrit par \"%s\", licence: %s"
+
+msgid " (none)"
+msgstr " (aucun)"
+
#, c-format
msgid "%s%s: unable to call function \"%s\", script is not initialized"
msgstr ""
diff --git a/po/hu.po b/po/hu.po
index fda7af3a2..3353e103e 100644
--- a/po/hu.po
+++ b/po/hu.po
@@ -12,7 +12,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat 0.2.7-dev\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
-"POT-Creation-Date: 2008-01-11 14:53+0100\n"
+"POT-Creation-Date: 2008-01-14 11:13+0100\n"
"PO-Revision-Date: 2007-10-10 18:07+0200\n"
"Last-Translator: Andras Voroskoi <voroskoi@frugalware.org>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@@ -4095,47 +4095,35 @@ msgid "%s%s: registered script \"%s\", version %s (%s)"
msgstr ""
#, fuzzy, c-format
-msgid "%s%s: error: %s"
-msgstr "%sSzerver: %s%s\n"
-
-#, c-format
-msgid "%s%s: function \"%s\" must return one valid value (%d)"
-msgstr ""
+msgid "%s%s: unable to run function \"%s\""
+msgstr "Nem sikerült a(z) \"%s\" naplófájlt írni\n"
#, fuzzy, c-format
-msgid "%s%s: function \"%s\" is internally misused"
-msgstr "%s a \"%s\" modul nem található\n"
+msgid "%s%s: error: %s"
+msgstr "%sSzerver: %s%s\n"
#, fuzzy, c-format
-msgid "%s%s: not enough memory in function \"%s\""
-msgstr "%s nincs elegendő memória új DCC számára\n"
+msgid "%s%s: script \"%s\" not found"
+msgstr "%s a \"%s\" szerver nem található\n"
#, fuzzy, c-format
-msgid "%s%s: loading Perl script \"%s\""
+msgid "%s%s: loading script \"%s\""
msgstr "folyamat: \"%s\" szerver betöltése\n"
#, fuzzy, c-format
-msgid "%s%s: script \"%s\" not found"
-msgstr "%s a \"%s\" szerver nem található\n"
-
-#, fuzzy, c-format
msgid "%s%s: unable to create new sub-interpreter"
msgstr "%s nem sikerült a szervert létrehozni\n"
#, fuzzy, c-format
-msgid "%s%s: not enough memory to parse file \"%s\""
-msgstr "%s nincs elegendő memória új DCC számára\n"
+msgid "%s%s: unable to redirect stdout and stderr"
+msgstr "%s nem sikerült a szervert létrehozni\n"
#, fuzzy, c-format
-msgid "%s%s: unable to parse file \"%s\""
+msgid "%s%s: unable to load file \"%s\""
msgstr "Nem sikerült a(z) \"%s\" naplófájlt írni\n"
#, fuzzy, c-format
-msgid "%s%s: unable to run file \"%s\""
-msgstr "Nem sikerült a(z) \"%s\" naplófájlt írni\n"
-
-#, fuzzy, c-format
-msgid "%s%s: unknown error while loading file \"%s\""
+msgid "%s%s: unable to execute file \"%s\""
msgstr "Nem sikerült a(z) \"%s\" naplófájlt írni\n"
#, fuzzy, c-format
@@ -4156,36 +4144,123 @@ msgstr "A \"%s\" modul eltávolítva.\n"
msgid "%s%s: script \"%s\" not loaded"
msgstr "%s a \"%s\" szerver nem található\n"
-msgid "Registered Perl scripts:"
-msgstr ""
+#, fuzzy, c-format
+msgid "%s%s: unknown option for command \"%s\""
+msgstr "%s ismeretlen opció a \"%s\" parancsnak\n"
#, c-format
-msgid " %s v%s (%s), by %s, license %s"
+msgid "%s%s: function \"%s\" must return one valid value (%d)"
msgstr ""
#, fuzzy, c-format
-msgid "%s%s: unknown option for command \"%s\""
-msgstr "%s ismeretlen opció a \"%s\" parancsnak\n"
+msgid "%s%s: function \"%s\" is internally misused"
+msgstr "%s a \"%s\" modul nem található\n"
+
+#, fuzzy, c-format
+msgid "%s%s: not enough memory in function \"%s\""
+msgstr "%s nincs elegendő memória új DCC számára\n"
+
+#, fuzzy, c-format
+msgid "%s%s: not enough memory to parse file \"%s\""
+msgstr "%s nincs elegendő memória új DCC számára\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to parse file \"%s\""
+msgstr "Nem sikerült a(z) \"%s\" naplófájlt írni\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to run file \"%s\""
+msgstr "Nem sikerült a(z) \"%s\" naplófájlt írni\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unknown error while loading file \"%s\""
+msgstr "Nem sikerült a(z) \"%s\" naplófájlt írni\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to initialize %s"
+msgstr "%s nem sikerült a modult betölteni \"%s\"\n"
+
+#, fuzzy, c-format
+msgid "%s%s unable to run function \"%s\""
+msgstr "Nem sikerült a(z) \"%s\" naplófájlt írni\n"
+
+#, fuzzy, c-format
+msgid "%s%s: function \"%s\" must return a valid value"
+msgstr "%s a \"%s\" modul nem található\n"
+
+#, c-format
+msgid "%s: stdout/stderr: %s%s"
+msgstr ""
#, fuzzy, c-format
-msgid "%s%s: unable to initialize Perl"
+msgid "%s%s: unable to initialize WeeChat module"
msgstr "%s nem sikerült a modult betölteni \"%s\"\n"
+#, fuzzy, c-format
+msgid "%s%s: unable to redirect stdout"
+msgstr "Nem sikerült a(z) \"%s\" naplófájlt írni\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to redirect stderr"
+msgstr "%s nem sikerült a szervert létrehozni\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to launch global interpreter"
+msgstr "%s nem sikerült a szervert létrehozni\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to get current interpreter state"
+msgstr "%s nem sikerült a szervert létrehozni\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to free interpreter"
+msgstr "%s nem sikerült a szervert létrehozni\n"
+
+#, fuzzy, c-format
+msgid "%s%s: error: \"%s\""
+msgstr "%sSzerver: %s%s\n"
+
+#, fuzzy, c-format
+msgid "%s%s: stdout/stderr: %s%s"
+msgstr "%sSzerver: %s%s\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to read file \"%s\""
+msgstr "Nem sikerült a(z) \"%s\" naplófájlt írni\n"
+
+#, fuzzy, c-format
+msgid "%s%s: error while loading file \"%s\""
+msgstr "Nem sikerült a(z) \"%s\" naplófájlt írni\n"
+
+#, fuzzy, c-format
+msgid "%s%s: function \"weechat_init\" is missing in file \"%s\""
+msgstr "Nem sikerült a(z) \"%s\" naplófájlt írni\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to eval function \"weechat_init\" in file \"%s\""
+msgstr "Nem sikerült a(z) \"%s\" naplófájlt írni\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to eval WeeChat ruby internal code"
+msgstr "%s nem sikerült a szervert létrehozni\n"
+
#, fuzzy
-msgid "list/load/unload Perl scripts"
+msgid "list/load/unload scripts"
msgstr "modulok listázása/betöltése/eltávolítása"
#, fuzzy
-msgid "[load filename] | [autoload] | [reload] | [unload [script]]"
+msgid ""
+"[list [name]] | [listfull [name]] [load filename] | [autoload] | [reload] | "
+"[unload [name]]"
msgstr ""
"[list [név]] | [listfull [név]] | [load fájlnév] | [autoload] | [reload "
"[név]] | [unload [név]]"
msgid ""
-"filename: Perl script (file) to load\n"
-"script: script name to unload\n"
+"filename: script (file) to load\n"
+"name: a script name\n"
"\n"
-"Without argument, /perl command lists all loaded Perl scripts."
+"Without argument, this command lists all loaded scripts."
msgstr ""
#, c-format
@@ -4202,6 +4277,23 @@ msgstr ""
msgid "%s: error loading script \"%s\" (not enough memory)"
msgstr "%s nem sikerült a modult betölteni \"%s\" (nincs elég memória)\n"
+#. TRANSLATORS: %s is language (for example "perl")
+#, fuzzy, c-format
+msgid "%s scripts loaded:"
+msgstr "FIFO cső bezárva\n"
+
+#, fuzzy, c-format
+msgid " file: %s"
+msgstr " IRC(%s)\n"
+
+#, c-format
+msgid " written by \"%s\", license: %s"
+msgstr ""
+
+#, fuzzy
+msgid " (none)"
+msgstr "(ismeretlen)"
+
#, c-format
msgid "%s%s: unable to call function \"%s\", script is not initialized"
msgstr ""
@@ -4211,8 +4303,42 @@ msgid "%s%s: wrong arguments for function \"%s\""
msgstr "%s rossz argumentum a \"%s\" parancsnak\n"
#, fuzzy
-#~ msgid "%s%s: scripts unloaded"
-#~ msgstr "FIFO cső bezárva\n"
+#~ msgid " %s%s%s v%s - %s"
+#~ msgstr " a következőtől: %s%s %s(%s%s%s)"
+
+#, fuzzy
+#~ msgid ""
+#~ "[list [name]] | [listfull [name]] [load filename] | [autoload] | [reload] "
+#~ "| [unload [script]]"
+#~ msgstr ""
+#~ "[list [név]] | [listfull [név]] | [load fájlnév] | [autoload] | [reload "
+#~ "[név]] | [unload [név]]"
+
+#, fuzzy
+#~ msgid "%s%s: not enough memory for function \"%s\""
+#~ msgstr "%s nincs elegendő memória új DCC számára\n"
+
+#, fuzzy
+#~ msgid "[load filename] | [autoload] | [reload] | [unload [script]]"
+#~ msgstr ""
+#~ "[list [név]] | [listfull [név]] | [load fájlnév] | [autoload] | [reload "
+#~ "[név]] | [unload [név]]"
+
+#, fuzzy
+#~ msgid "list/load/unload Perl scripts"
+#~ msgstr "modulok listázása/betöltése/eltávolítása"
+
+#, fuzzy
+#~ msgid "list/load/unload Python scripts"
+#~ msgstr "modulok listázása/betöltése/eltávolítása"
+
+#, fuzzy
+#~ msgid "list/load/unload Ruby scripts"
+#~ msgstr "modulok listázása/betöltése/eltávolítása"
+
+#, fuzzy
+#~ msgid "%s%s: loading Perl script \"%s\""
+#~ msgstr "folyamat: \"%s\" szerver betöltése\n"
#, fuzzy
#~ msgid "%s%s: plugin ended"
diff --git a/po/ru.po b/po/ru.po
index 2596e9f8a..92fff9540 100644
--- a/po/ru.po
+++ b/po/ru.po
@@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat 0.2.7-dev\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
-"POT-Creation-Date: 2008-01-11 14:53+0100\n"
+"POT-Creation-Date: 2008-01-14 11:13+0100\n"
"PO-Revision-Date: 2007-09-06 12:44+0200\n"
"Last-Translator: Pavel Shevchuk <stlwrt@gmail.com>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@@ -4077,47 +4077,35 @@ msgid "%s%s: registered script \"%s\", version %s (%s)"
msgstr ""
#, fuzzy, c-format
-msgid "%s%s: error: %s"
-msgstr "%sСервер: %s%s\n"
-
-#, c-format
-msgid "%s%s: function \"%s\" must return one valid value (%d)"
-msgstr ""
+msgid "%s%s: unable to run function \"%s\""
+msgstr "Не могу записать лог-файл \"%s\"\n"
#, fuzzy, c-format
-msgid "%s%s: function \"%s\" is internally misused"
-msgstr "%s plugin \"%s\" не найден\n"
+msgid "%s%s: error: %s"
+msgstr "%sСервер: %s%s\n"
#, fuzzy, c-format
-msgid "%s%s: not enough memory in function \"%s\""
-msgstr "%s недостаточно памяти для нового DCC\n"
+msgid "%s%s: script \"%s\" not found"
+msgstr "%s сервер \"%s\" не найден\n"
#, fuzzy, c-format
-msgid "%s%s: loading Perl script \"%s\""
+msgid "%s%s: loading script \"%s\""
msgstr "сессия: загружаю сервер \"%s\"\n"
#, fuzzy, c-format
-msgid "%s%s: script \"%s\" not found"
-msgstr "%s сервер \"%s\" не найден\n"
-
-#, fuzzy, c-format
msgid "%s%s: unable to create new sub-interpreter"
msgstr "%s не могу создать сервер\n"
#, fuzzy, c-format
-msgid "%s%s: not enough memory to parse file \"%s\""
-msgstr "%s недостаточно памяти для нового DCC\n"
+msgid "%s%s: unable to redirect stdout and stderr"
+msgstr "%s не могу создать сервер\n"
#, fuzzy, c-format
-msgid "%s%s: unable to parse file \"%s\""
+msgid "%s%s: unable to load file \"%s\""
msgstr "Не могу записать лог-файл \"%s\"\n"
#, fuzzy, c-format
-msgid "%s%s: unable to run file \"%s\""
-msgstr "Не могу записать лог-файл \"%s\"\n"
-
-#, fuzzy, c-format
-msgid "%s%s: unknown error while loading file \"%s\""
+msgid "%s%s: unable to execute file \"%s\""
msgstr "Не могу записать лог-файл \"%s\"\n"
#, fuzzy, c-format
@@ -4138,36 +4126,123 @@ msgstr "Plugin \"%s\" выгружен.\n"
msgid "%s%s: script \"%s\" not loaded"
msgstr "%s сервер \"%s\" не найден\n"
-msgid "Registered Perl scripts:"
-msgstr ""
+#, fuzzy, c-format
+msgid "%s%s: unknown option for command \"%s\""
+msgstr "%s неизвестный параметр для команды \"%s\"\n"
#, c-format
-msgid " %s v%s (%s), by %s, license %s"
+msgid "%s%s: function \"%s\" must return one valid value (%d)"
msgstr ""
#, fuzzy, c-format
-msgid "%s%s: unknown option for command \"%s\""
-msgstr "%s неизвестный параметр для команды \"%s\"\n"
+msgid "%s%s: function \"%s\" is internally misused"
+msgstr "%s plugin \"%s\" не найден\n"
+
+#, fuzzy, c-format
+msgid "%s%s: not enough memory in function \"%s\""
+msgstr "%s недостаточно памяти для нового DCC\n"
+
+#, fuzzy, c-format
+msgid "%s%s: not enough memory to parse file \"%s\""
+msgstr "%s недостаточно памяти для нового DCC\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to parse file \"%s\""
+msgstr "Не могу записать лог-файл \"%s\"\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to run file \"%s\""
+msgstr "Не могу записать лог-файл \"%s\"\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unknown error while loading file \"%s\""
+msgstr "Не могу записать лог-файл \"%s\"\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to initialize %s"
+msgstr "%s не могу инициализировать plugin \"%s\"\n"
+
+#, fuzzy, c-format
+msgid "%s%s unable to run function \"%s\""
+msgstr "Не могу записать лог-файл \"%s\"\n"
+
+#, fuzzy, c-format
+msgid "%s%s: function \"%s\" must return a valid value"
+msgstr "%s plugin \"%s\" не найден\n"
+
+#, c-format
+msgid "%s: stdout/stderr: %s%s"
+msgstr ""
#, fuzzy, c-format
-msgid "%s%s: unable to initialize Perl"
+msgid "%s%s: unable to initialize WeeChat module"
msgstr "%s не могу инициализировать plugin \"%s\"\n"
+#, fuzzy, c-format
+msgid "%s%s: unable to redirect stdout"
+msgstr "Не могу записать лог-файл \"%s\"\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to redirect stderr"
+msgstr "%s не могу создать сервер\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to launch global interpreter"
+msgstr "%s не могу создать сервер\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to get current interpreter state"
+msgstr "%s не могу создать сервер\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to free interpreter"
+msgstr "%s не могу создать сервер\n"
+
+#, fuzzy, c-format
+msgid "%s%s: error: \"%s\""
+msgstr "%sСервер: %s%s\n"
+
+#, fuzzy, c-format
+msgid "%s%s: stdout/stderr: %s%s"
+msgstr "%sСервер: %s%s\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to read file \"%s\""
+msgstr "Не могу записать лог-файл \"%s\"\n"
+
+#, fuzzy, c-format
+msgid "%s%s: error while loading file \"%s\""
+msgstr "Не могу записать лог-файл \"%s\"\n"
+
+#, fuzzy, c-format
+msgid "%s%s: function \"weechat_init\" is missing in file \"%s\""
+msgstr "Не могу записать лог-файл \"%s\"\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to eval function \"weechat_init\" in file \"%s\""
+msgstr "Не могу записать лог-файл \"%s\"\n"
+
+#, fuzzy, c-format
+msgid "%s%s: unable to eval WeeChat ruby internal code"
+msgstr "%s не могу создать сервер\n"
+
#, fuzzy
-msgid "list/load/unload Perl scripts"
+msgid "list/load/unload scripts"
msgstr "перечислить/загрузить/выгрузить plugin'ы"
#, fuzzy
-msgid "[load filename] | [autoload] | [reload] | [unload [script]]"
+msgid ""
+"[list [name]] | [listfull [name]] [load filename] | [autoload] | [reload] | "
+"[unload [name]]"
msgstr ""
"[list [имя]] | [listfull [имя]] | [load имя_файла] | [autoload] | [reload "
"[имя]] | [unload [имя]]"
msgid ""
-"filename: Perl script (file) to load\n"
-"script: script name to unload\n"
+"filename: script (file) to load\n"
+"name: a script name\n"
"\n"
-"Without argument, /perl command lists all loaded Perl scripts."
+"Without argument, this command lists all loaded scripts."
msgstr ""
#, c-format
@@ -4184,6 +4259,23 @@ msgstr ""
msgid "%s: error loading script \"%s\" (not enough memory)"
msgstr "%s не могу загрузить plugin \"%s\" (недостаточно памяти)\n"
+#. TRANSLATORS: %s is language (for example "perl")
+#, fuzzy, c-format
+msgid "%s scripts loaded:"
+msgstr "FIFO pipe закрыт\n"
+
+#, fuzzy, c-format
+msgid " file: %s"
+msgstr " IRC(%s)\n"
+
+#, c-format
+msgid " written by \"%s\", license: %s"
+msgstr ""
+
+#, fuzzy
+msgid " (none)"
+msgstr "(неизвестен)"
+
#, c-format
msgid "%s%s: unable to call function \"%s\", script is not initialized"
msgstr ""
@@ -4193,8 +4285,42 @@ msgid "%s%s: wrong arguments for function \"%s\""
msgstr "%s некорректные аргументы команды \"%s\"\n"
#, fuzzy
-#~ msgid "%s%s: scripts unloaded"
-#~ msgstr "FIFO pipe закрыт\n"
+#~ msgid " %s%s%s v%s - %s"
+#~ msgstr " пользователем %s%s %s(%s%s%s)"
+
+#, fuzzy
+#~ msgid ""
+#~ "[list [name]] | [listfull [name]] [load filename] | [autoload] | [reload] "
+#~ "| [unload [script]]"
+#~ msgstr ""
+#~ "[list [имя]] | [listfull [имя]] | [load имя_файла] | [autoload] | [reload "
+#~ "[имя]] | [unload [имя]]"
+
+#, fuzzy
+#~ msgid "%s%s: not enough memory for function \"%s\""
+#~ msgstr "%s недостаточно памяти для нового DCC\n"
+
+#, fuzzy
+#~ msgid "[load filename] | [autoload] | [reload] | [unload [script]]"
+#~ msgstr ""
+#~ "[list [имя]] | [listfull [имя]] | [load имя_файла] | [autoload] | [reload "
+#~ "[имя]] | [unload [имя]]"
+
+#, fuzzy
+#~ msgid "list/load/unload Perl scripts"
+#~ msgstr "перечислить/загрузить/выгрузить plugin'ы"
+
+#, fuzzy
+#~ msgid "list/load/unload Python scripts"
+#~ msgstr "перечислить/загрузить/выгрузить plugin'ы"
+
+#, fuzzy
+#~ msgid "list/load/unload Ruby scripts"
+#~ msgstr "перечислить/загрузить/выгрузить plugin'ы"
+
+#, fuzzy
+#~ msgid "%s%s: loading Perl script \"%s\""
+#~ msgstr "сессия: загружаю сервер \"%s\"\n"
#, fuzzy
#~ msgid "%s%s: plugin ended"
diff --git a/po/srcfiles.cmake b/po/srcfiles.cmake
index cb596701e..83fbcedfe 100644
--- a/po/srcfiles.cmake
+++ b/po/srcfiles.cmake
@@ -126,14 +126,27 @@ SET(WEECHAT_SOURCES
./src/plugins/plugin.h
./src/plugins/plugin-infolist.c
./src/plugins/plugin-infolist.h
-./src/plugins/scripts/lua/lua.c
+./src/plugins/scripts/lua/weechat-lua-api.c
+./src/plugins/scripts/lua/weechat-lua-api.h
+./src/plugins/scripts/lua/weechat-lua.c
+./src/plugins/scripts/lua/weechat-lua.h
./src/plugins/scripts/perl/weechat-perl-api.c
./src/plugins/scripts/perl/weechat-perl-api.h
./src/plugins/scripts/perl/weechat-perl.c
./src/plugins/scripts/perl/weechat-perl.h
-./src/plugins/scripts/python/python.c
-./src/plugins/scripts/ruby/ruby.c
+./src/plugins/scripts/python/weechat-python-api.c
+./src/plugins/scripts/python/weechat-python-api.h
+./src/plugins/scripts/python/weechat-python.c
+./src/plugins/scripts/python/weechat-python.h
+./src/plugins/scripts/ruby/weechat-ruby-api.c
+./src/plugins/scripts/ruby/weechat-ruby-api.h
+./src/plugins/scripts/ruby/weechat-ruby.c
+./src/plugins/scripts/ruby/weechat-ruby.h
+./src/plugins/scripts/script-api.c
+./src/plugins/scripts/script-api.h
./src/plugins/scripts/script.c
+./src/plugins/scripts/script-callback.c
+./src/plugins/scripts/script-callback.h
./src/plugins/scripts/script.h
./src/plugins/trigger/dump.c
./src/plugins/trigger/trigger.c
diff --git a/po/weechat.pot b/po/weechat.pot
index 54b90a40c..1a1fe73c7 100644
--- a/po/weechat.pot
+++ b/po/weechat.pot
@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
-"POT-Creation-Date: 2008-01-11 14:53+0100\n"
+"POT-Creation-Date: 2008-01-14 11:13+0100\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
@@ -3549,31 +3549,67 @@ msgid "%s%s: registered script \"%s\", version %s (%s)"
msgstr ""
#, c-format
+msgid "%s%s: unable to run function \"%s\""
+msgstr ""
+
+#, c-format
msgid "%s%s: error: %s"
msgstr ""
#, c-format
-msgid "%s%s: function \"%s\" must return one valid value (%d)"
+msgid "%s%s: script \"%s\" not found"
msgstr ""
#, c-format
-msgid "%s%s: function \"%s\" is internally misused"
+msgid "%s%s: loading script \"%s\""
msgstr ""
#, c-format
-msgid "%s%s: not enough memory in function \"%s\""
+msgid "%s%s: unable to create new sub-interpreter"
msgstr ""
#, c-format
-msgid "%s%s: loading Perl script \"%s\""
+msgid "%s%s: unable to redirect stdout and stderr"
msgstr ""
#, c-format
-msgid "%s%s: script \"%s\" not found"
+msgid "%s%s: unable to load file \"%s\""
msgstr ""
#, c-format
-msgid "%s%s: unable to create new sub-interpreter"
+msgid "%s%s: unable to execute file \"%s\""
+msgstr ""
+
+#, c-format
+msgid "%s%s: function \"register\" not found (or failed) in file \"%s\""
+msgstr ""
+
+#, c-format
+msgid "%s%s: unloading script \"%s\""
+msgstr ""
+
+#, c-format
+msgid "%s%s: script \"%s\" unloaded"
+msgstr ""
+
+#, c-format
+msgid "%s%s: script \"%s\" not loaded"
+msgstr ""
+
+#, c-format
+msgid "%s%s: unknown option for command \"%s\""
+msgstr ""
+
+#, c-format
+msgid "%s%s: function \"%s\" must return one valid value (%d)"
+msgstr ""
+
+#, c-format
+msgid "%s%s: function \"%s\" is internally misused"
+msgstr ""
+
+#, c-format
+msgid "%s%s: not enough memory in function \"%s\""
msgstr ""
#, c-format
@@ -3593,47 +3629,86 @@ msgid "%s%s: unknown error while loading file \"%s\""
msgstr ""
#, c-format
-msgid "%s%s: function \"register\" not found (or failed) in file \"%s\""
+msgid "%s%s: unable to initialize %s"
msgstr ""
#, c-format
-msgid "%s%s: unloading script \"%s\""
+msgid "%s%s unable to run function \"%s\""
msgstr ""
#, c-format
-msgid "%s%s: script \"%s\" unloaded"
+msgid "%s%s: function \"%s\" must return a valid value"
msgstr ""
#, c-format
-msgid "%s%s: script \"%s\" not loaded"
+msgid "%s: stdout/stderr: %s%s"
msgstr ""
-msgid "Registered Perl scripts:"
+#, c-format
+msgid "%s%s: unable to initialize WeeChat module"
msgstr ""
#, c-format
-msgid " %s v%s (%s), by %s, license %s"
+msgid "%s%s: unable to redirect stdout"
msgstr ""
#, c-format
-msgid "%s%s: unknown option for command \"%s\""
+msgid "%s%s: unable to redirect stderr"
+msgstr ""
+
+#, c-format
+msgid "%s%s: unable to launch global interpreter"
+msgstr ""
+
+#, c-format
+msgid "%s%s: unable to get current interpreter state"
+msgstr ""
+
+#, c-format
+msgid "%s%s: unable to free interpreter"
msgstr ""
#, c-format
-msgid "%s%s: unable to initialize Perl"
+msgid "%s%s: error: \"%s\""
msgstr ""
-msgid "list/load/unload Perl scripts"
+#, c-format
+msgid "%s%s: stdout/stderr: %s%s"
msgstr ""
-msgid "[load filename] | [autoload] | [reload] | [unload [script]]"
+#, c-format
+msgid "%s%s: unable to read file \"%s\""
+msgstr ""
+
+#, c-format
+msgid "%s%s: error while loading file \"%s\""
+msgstr ""
+
+#, c-format
+msgid "%s%s: function \"weechat_init\" is missing in file \"%s\""
+msgstr ""
+
+#, c-format
+msgid "%s%s: unable to eval function \"weechat_init\" in file \"%s\""
+msgstr ""
+
+#, c-format
+msgid "%s%s: unable to eval WeeChat ruby internal code"
+msgstr ""
+
+msgid "list/load/unload scripts"
msgstr ""
msgid ""
-"filename: Perl script (file) to load\n"
-"script: script name to unload\n"
+"[list [name]] | [listfull [name]] [load filename] | [autoload] | [reload] | "
+"[unload [name]]"
+msgstr ""
+
+msgid ""
+"filename: script (file) to load\n"
+"name: a script name\n"
"\n"
-"Without argument, /perl command lists all loaded Perl scripts."
+"Without argument, this command lists all loaded scripts."
msgstr ""
#, c-format
@@ -3650,6 +3725,22 @@ msgstr ""
msgid "%s: error loading script \"%s\" (not enough memory)"
msgstr ""
+#. TRANSLATORS: %s is language (for example "perl")
+#, c-format
+msgid "%s scripts loaded:"
+msgstr ""
+
+#, c-format
+msgid " file: %s"
+msgstr ""
+
+#, c-format
+msgid " written by \"%s\", license: %s"
+msgstr ""
+
+msgid " (none)"
+msgstr ""
+
#, c-format
msgid "%s%s: unable to call function \"%s\", script is not initialized"
msgstr ""
diff --git a/src/plugins/scripts/lua/weechat-lua.c b/src/plugins/scripts/lua/weechat-lua.c
index 17f0a1471..d06923369 100644
--- a/src/plugins/scripts/lua/weechat-lua.c
+++ b/src/plugins/scripts/lua/weechat-lua.c
@@ -23,15 +23,8 @@
#include <lua.h>
#include <lualib.h>
#include <lauxlib.h>
-
-//#include <stdio.h>
#include <stdlib.h>
#include <string.h>
-//#include <stdarg.h>
-//#include <time.h>
-//#include <sys/socket.h>
-//#include <netinet/in.h>
-//#include <arpa/inet.h>
#include "../../weechat-plugin.h"
#include "../script.h"
@@ -132,7 +125,7 @@ weechat_lua_load (char *filename)
char *weechat_lua_code = {
"weechat_outputs = {\n"
" write = function (self, str)\n"
- " weechat.print(\"Lua stdout/stderr : \" .. str)\n"
+ " weechat.print(\"\", \"lua: stdout/stderr: \" .. str)\n"
" end\n"
"}\n"
"io.stdout = weechat_outputs\n"
@@ -328,11 +321,7 @@ int
weechat_lua_command_cb (void *data, struct t_gui_buffer *buffer,
int argc, char **argv, char **argv_eol)
{
- //int handler_found, modifier_found;
char *path_script;
- struct t_plugin_script *ptr_script;
- //t_plugin_handler *ptr_handler;
- //t_plugin_modifier *ptr_modifier;
/* make C compiler happy */
(void) data;
@@ -340,162 +329,29 @@ weechat_lua_command_cb (void *data, struct t_gui_buffer *buffer,
if (argc == 1)
{
- /* list registered Lua scripts */
- weechat_printf (NULL, "");
- weechat_printf (NULL,
- weechat_gettext ("Registered %s scripts:"),
- "lua");
- if (lua_scripts)
- {
- for (ptr_script = lua_scripts; ptr_script;
- ptr_script = ptr_script->next_script)
- {
- weechat_printf (NULL,
- weechat_gettext (" %s v%s (%s), by %s, "
- "license %s"),
- ptr_script->name,
- ptr_script->version,
- ptr_script->description,
- ptr_script->author,
- ptr_script->license);
- }
- }
- else
- weechat_printf (NULL, weechat_gettext (" (none)"));
-
- /*
- // list Lua message handlers
- plugin->print_server (plugin, "");
- plugin->print_server (plugin, "Lua message handlers:");
- handler_found = 0;
- for (ptr_handler = plugin->handlers;
- ptr_handler; ptr_handler = ptr_handler->next_handler)
- {
- if ((ptr_handler->type == PLUGIN_HANDLER_MESSAGE)
- && (ptr_handler->handler_args))
- {
- handler_found = 1;
- plugin->print_server (plugin, " IRC(%s) => Lua(%s)",
- ptr_handler->irc_command,
- ptr_handler->handler_args);
- }
- }
- if (!handler_found)
- plugin->print_server (plugin, " (none)");
-
- // list Lua command handlers
- plugin->print_server (plugin, "");
- plugin->print_server (plugin, "Lua command handlers:");
- handler_found = 0;
- for (ptr_handler = plugin->handlers;
- ptr_handler; ptr_handler = ptr_handler->next_handler)
- {
- if ((ptr_handler->type == PLUGIN_HANDLER_COMMAND)
- && (ptr_handler->handler_args))
- {
- handler_found = 1;
- plugin->print_server (plugin, " /%s => Lua(%s)",
- ptr_handler->command,
- ptr_handler->handler_args);
- }
- }
- if (!handler_found)
- plugin->print_server (plugin, " (none)");
-
- // list Lua timer handlers
- plugin->print_server (plugin, "");
- plugin->print_server (plugin, "Lua timer handlers:");
- handler_found = 0;
- for (ptr_handler = plugin->handlers;
- ptr_handler; ptr_handler = ptr_handler->next_handler)
- {
- if ((ptr_handler->type == PLUGIN_HANDLER_TIMER)
- && (ptr_handler->handler_args))
- {
- handler_found = 1;
- plugin->print_server (plugin, " %d seconds => Lua(%s)",
- ptr_handler->interval,
- ptr_handler->handler_args);
- }
- }
- if (!handler_found)
- plugin->print_server (plugin, " (none)");
-
- // list Lua keyboard handlers
- plugin->print_server (plugin, "");
- plugin->print_server (plugin, "Lua keyboard handlers:");
- handler_found = 0;
- for (ptr_handler = plugin->handlers;
- ptr_handler; ptr_handler = ptr_handler->next_handler)
+ script_display_list (weechat_lua_plugin, lua_scripts,
+ NULL, 0);
+ }
+ else if (argc == 2)
+ {
+ if (weechat_strcasecmp (argv[1], "list") == 0)
{
- if ((ptr_handler->type == PLUGIN_HANDLER_KEYBOARD)
- && (ptr_handler->handler_args))
- {
- handler_found = 1;
- plugin->print_server (plugin, " Lua(%s)",
- ptr_handler->handler_args);
- }
+ script_display_list (weechat_lua_plugin, lua_scripts,
+ NULL, 0);
}
- if (!handler_found)
- plugin->print_server (plugin, " (none)");
-
- // list Lua event handlers
- plugin->print_server (plugin, "");
- plugin->print_server (plugin, "Lua event handlers:");
- handler_found = 0;
- for (ptr_handler = plugin->handlers;
- ptr_handler; ptr_handler = ptr_handler->next_handler)
+ else if (weechat_strcasecmp (argv[1], "listfull") == 0)
{
- if ((ptr_handler->type == PLUGIN_HANDLER_EVENT)
- && (ptr_handler->handler_args))
- {
- handler_found = 1;
- plugin->print_server (plugin, " %s => Lua(%s)",
- ptr_handler->event,
- ptr_handler->handler_args);
- }
+ script_display_list (weechat_lua_plugin, lua_scripts,
+ NULL, 1);
}
- if (!handler_found)
- plugin->print_server (plugin, " (none)");
-
- // list Lua modifiers
- plugin->print_server (plugin, "");
- plugin->print_server (plugin, "Lua modifiers:");
- modifier_found = 0;
- for (ptr_modifier = plugin->modifiers;
- ptr_modifier; ptr_modifier = ptr_modifier->next_modifier)
+ else if (weechat_strcasecmp (argv[1], "autoload") == 0)
{
- modifier_found = 1;
- if (ptr_modifier->type == PLUGIN_MODIFIER_IRC_IN)
- plugin->print_server (plugin, " IRC(%s, %s) => Lua(%s)",
- ptr_modifier->command,
- PLUGIN_MODIFIER_IRC_IN_STR,
- ptr_modifier->modifier_args);
- else if (ptr_modifier->type == PLUGIN_MODIFIER_IRC_USER)
- plugin->print_server (plugin, " IRC(%s, %s) => Lua(%s)",
- ptr_modifier->command,
- PLUGIN_MODIFIER_IRC_USER_STR,
- ptr_modifier->modifier_args);
- else if (ptr_modifier->type == PLUGIN_MODIFIER_IRC_OUT)
- plugin->print_server (plugin, " IRC(%s, %s) => Lua(%s)",
- ptr_modifier->command,
- PLUGIN_MODIFIER_IRC_OUT_STR,
- ptr_modifier->modifier_args);
+ script_auto_load (weechat_lua_plugin, &weechat_lua_load_cb);
}
- if (!modifier_found)
- plugin->print_server (plugin, " (none)");
- */
- }
- else if (argc == 2)
- {
- if (weechat_strcasecmp (argv[1], "autoload") == 0)
- script_auto_load (weechat_lua_plugin,
- "lua", &weechat_lua_load_cb);
else if (weechat_strcasecmp (argv[1], "reload") == 0)
{
weechat_lua_unload_all ();
- script_auto_load (weechat_lua_plugin,
- "lua", &weechat_lua_load_cb);
+ script_auto_load (weechat_lua_plugin, &weechat_lua_load_cb);
}
else if (weechat_strcasecmp (argv[1], "unload") == 0)
{
@@ -504,11 +360,21 @@ weechat_lua_command_cb (void *data, struct t_gui_buffer *buffer,
}
else
{
- if (weechat_strcasecmp (argv[1], "load") == 0)
+ if (weechat_strcasecmp (argv[1], "list") == 0)
+ {
+ script_display_list (weechat_lua_plugin, lua_scripts,
+ argv_eol[2], 0);
+ }
+ else if (weechat_strcasecmp (argv[1], "listfull") == 0)
+ {
+ script_display_list (weechat_lua_plugin, lua_scripts,
+ argv_eol[2], 1);
+ }
+ else if (weechat_strcasecmp (argv[1], "load") == 0)
{
/* load Lua script */
path_script = script_search_full_name (weechat_lua_plugin,
- "lua", argv_eol[2]);
+ argv_eol[2]);
weechat_lua_load ((path_script) ? path_script : argv_eol[2]);
if (path_script)
free (path_script);
@@ -558,26 +424,10 @@ weechat_plugin_init (struct t_weechat_plugin *plugin)
{
weechat_lua_plugin = plugin;
-
- weechat_hook_command ("lua",
- weechat_gettext ("list/load/unload Lua scripts"),
- weechat_gettext ("[load filename] | [autoload] | "
- "[reload] | [unload [script]]"),
- weechat_gettext ("filename: Lua script (file) to "
- "load\n"
- "script: script name to unload\n\n"
- "Without argument, /lua command "
- "lists all loaded Lua scripts."),
- "load|autoload|reload|unload %f",
- &weechat_lua_command_cb, NULL);
-
- weechat_mkdir_home ("lua", 0644);
- weechat_mkdir_home ("lua/autoload", 0644);
- weechat_hook_signal ("dump_data", &weechat_lua_dump_data_cb, NULL);
-
- script_init (weechat_lua_plugin);
- script_auto_load (weechat_lua_plugin, "lua", &weechat_lua_load_cb);
+ script_init (weechat_lua_plugin,
+ &weechat_lua_command_cb, &weechat_lua_dump_data_cb,
+ &weechat_lua_load_cb);
/* init ok */
return WEECHAT_RC_OK;
diff --git a/src/plugins/scripts/perl/weechat-perl.c b/src/plugins/scripts/perl/weechat-perl.c
index c34a80223..1486d93bb 100644
--- a/src/plugins/scripts/perl/weechat-perl.c
+++ b/src/plugins/scripts/perl/weechat-perl.c
@@ -98,8 +98,8 @@ char *perl_weechat_code =
" }"
" return 0;"
"}"
- "$SIG{__WARN__} = sub { weechat::print \"Perl error: $_[0]\", \"\"; };"
- "$SIG{__DIE__} = sub { weechat::print \"Perl error: $_[0]\", \"\"; };"
+ "$SIG{__WARN__} = sub { weechat::print(\"\", \"perl error: $_[0]\"); };"
+ "$SIG{__DIE__} = sub { weechat::print(\"\", \"perl error: $_[0]\"); };"
};
@@ -462,176 +462,37 @@ int
weechat_perl_command_cb (void *data, struct t_gui_buffer *buffer,
int argc, char **argv, char **argv_eol)
{
- //int handler_found, modifier_found;
char *path_script;
- struct t_plugin_script *ptr_script;
- //struct t_plugin_handler *ptr_handler;
- //struct t_plugin_modifier *ptr_modifier;
-
+
/* make C compiler happy */
(void) data;
(void) buffer;
if (argc == 1)
{
- /* list registered Perl scripts */
- weechat_printf (NULL, "");
- weechat_printf (NULL,
- weechat_gettext ("Registered %s scripts:"),
- "perl");
- if (perl_scripts)
- {
- for (ptr_script = perl_scripts; ptr_script;
- ptr_script = ptr_script->next_script)
- {
- weechat_printf (NULL,
- weechat_gettext (" %s v%s (%s), by %s, "
- "license %s"),
- ptr_script->name,
- ptr_script->version,
- ptr_script->description,
- ptr_script->author,
- ptr_script->license);
- }
- }
- else
- weechat_printf (NULL, weechat_gettext (" (none)"));
-
- /*
- // list Perl message handlers
- plugin->print_server (plugin, "");
- plugin->print_server (plugin, "Perl message handlers:");
- handler_found = 0;
- for (ptr_handler = plugin->handlers;
- ptr_handler; ptr_handler = ptr_handler->next_handler)
- {
- if ((ptr_handler->type == PLUGIN_HANDLER_MESSAGE)
- && (ptr_handler->handler_args))
- {
- handler_found = 1;
- plugin->print_server (plugin, " IRC(%s) => Perl(%s)",
- ptr_handler->irc_command,
- ptr_handler->handler_args);
- }
- }
- if (!handler_found)
- plugin->print_server (plugin, " (none)");
-
- // list Perl command handlers
- plugin->print_server (plugin, "");
- plugin->print_server (plugin, "Perl command handlers:");
- handler_found = 0;
- for (ptr_handler = plugin->handlers;
- ptr_handler; ptr_handler = ptr_handler->next_handler)
- {
- if ((ptr_handler->type == PLUGIN_HANDLER_COMMAND)
- && (ptr_handler->handler_args))
- {
- handler_found = 1;
- plugin->print_server (plugin, " /%s => Perl(%s)",
- ptr_handler->command,
- ptr_handler->handler_args);
- }
- }
- if (!handler_found)
- plugin->print_server (plugin, " (none)");
-
- // list Perl timer handlers
- plugin->print_server (plugin, "");
- plugin->print_server (plugin, "Perl timer handlers:");
- handler_found = 0;
- for (ptr_handler = plugin->handlers;
- ptr_handler; ptr_handler = ptr_handler->next_handler)
- {
- if ((ptr_handler->type == PLUGIN_HANDLER_TIMER)
- && (ptr_handler->handler_args))
- {
- handler_found = 1;
- plugin->print_server (plugin, " %d seconds => Perl(%s)",
- ptr_handler->interval,
- ptr_handler->handler_args);
- }
- }
- if (!handler_found)
- plugin->print_server (plugin, " (none)");
-
- // list Perl keyboard handlers
- plugin->print_server (plugin, "");
- plugin->print_server (plugin, "Perl keyboard handlers:");
- handler_found = 0;
- for (ptr_handler = plugin->handlers;
- ptr_handler; ptr_handler = ptr_handler->next_handler)
- {
- if ((ptr_handler->type == PLUGIN_HANDLER_KEYBOARD)
- && (ptr_handler->handler_args))
- {
- handler_found = 1;
- plugin->print_server (plugin, " Perl(%s)",
- ptr_handler->handler_args);
- }
- }
- if (!handler_found)
- plugin->print_server (plugin, " (none)");
-
- // list Perl event handlers
- plugin->print_server (plugin, "");
- plugin->print_server (plugin, "Perl event handlers:");
- handler_found = 0;
- for (ptr_handler = plugin->handlers;
- ptr_handler; ptr_handler = ptr_handler->next_handler)
+ script_display_list (weechat_perl_plugin, perl_scripts,
+ NULL, 0);
+ }
+ else if (argc == 2)
+ {
+ if (weechat_strcasecmp (argv[1], "list") == 0)
{
- if ((ptr_handler->type == PLUGIN_HANDLER_EVENT)
- && (ptr_handler->handler_args))
- {
- handler_found = 1;
- plugin->print_server (plugin, " %s => Perl(%s)",
- ptr_handler->event,
- ptr_handler->handler_args);
- }
+ script_display_list (weechat_perl_plugin, perl_scripts,
+ NULL, 0);
}
- if (!handler_found)
- plugin->print_server (plugin, " (none)");
-
- // list Perl modifiers
- plugin->print_server (plugin, "");
- plugin->print_server (plugin, "Perl modifiers:");
- modifier_found = 0;
- for (ptr_modifier = plugin->modifiers;
- ptr_modifier; ptr_modifier = ptr_modifier->next_modifier)
+ else if (weechat_strcasecmp (argv[1], "listfull") == 0)
{
- modifier_found = 1;
- if (ptr_modifier->type == PLUGIN_MODIFIER_IRC_IN)
- plugin->print_server (plugin, " IRC(%s, %s) => Perl(%s)",
- ptr_modifier->command,
- PLUGIN_MODIFIER_IRC_IN_STR,
- ptr_modifier->modifier_args);
- else if (ptr_modifier->type == PLUGIN_MODIFIER_IRC_USER)
- plugin->print_server (plugin, " IRC(%s, %s) => Perl(%s)",
- ptr_modifier->command,
- PLUGIN_MODIFIER_IRC_USER_STR,
- ptr_modifier->modifier_args);
- else if (ptr_modifier->type == PLUGIN_MODIFIER_IRC_OUT)
- plugin->print_server (plugin, " IRC(%s, %s) => Perl(%s)",
- ptr_modifier->command,
- PLUGIN_MODIFIER_IRC_OUT_STR,
- ptr_modifier->modifier_args);
+ script_display_list (weechat_perl_plugin, perl_scripts,
+ NULL, 1);
}
- if (!modifier_found)
- plugin->print_server (plugin, " (none)");
- */
- }
- else if (argc == 2)
- {
- if (weechat_strcasecmp (argv[1], "autoload") == 0)
+ else if (weechat_strcasecmp (argv[1], "autoload") == 0)
{
- script_auto_load (weechat_perl_plugin,
- "perl", &weechat_perl_load_cb);
+ script_auto_load (weechat_perl_plugin, &weechat_perl_load_cb);
}
else if (weechat_strcasecmp (argv[1], "reload") == 0)
{
weechat_perl_unload_all ();
- script_auto_load (weechat_perl_plugin,
- "perl", &weechat_perl_load_cb);
+ script_auto_load (weechat_perl_plugin, &weechat_perl_load_cb);
}
else if (weechat_strcasecmp (argv[1], "unload") == 0)
{
@@ -640,11 +501,21 @@ weechat_perl_command_cb (void *data, struct t_gui_buffer *buffer,
}
else
{
- if (weechat_strcasecmp (argv[1], "load") == 0)
+ if (weechat_strcasecmp (argv[1], "list") == 0)
+ {
+ script_display_list (weechat_perl_plugin, perl_scripts,
+ argv_eol[2], 0);
+ }
+ else if (weechat_strcasecmp (argv[1], "listfull") == 0)
+ {
+ script_display_list (weechat_perl_plugin, perl_scripts,
+ argv_eol[2], 1);
+ }
+ else if (weechat_strcasecmp (argv[1], "load") == 0)
{
/* load Perl script */
path_script = script_search_full_name (weechat_perl_plugin,
- "perl", argv_eol[2]);
+ argv_eol[2]);
weechat_perl_load ((path_script) ? path_script : argv_eol[2]);
if (path_script)
free (path_script);
@@ -712,25 +583,9 @@ weechat_plugin_init (struct t_weechat_plugin *plugin)
eval_pv (perl_weechat_code, TRUE);
#endif
- weechat_hook_command ("perl",
- weechat_gettext ("list/load/unload Perl scripts"),
- weechat_gettext ("[load filename] | [autoload] | "
- "[reload] | [unload [script]]"),
- weechat_gettext ("filename: Perl script (file) to "
- "load\n"
- "script: script name to unload\n\n"
- "Without argument, /perl command "
- "lists all loaded Perl scripts."),
- "load|autoload|reload|unload %f",
- &weechat_perl_command_cb, NULL);
-
- weechat_mkdir_home ("perl", 0644);
- weechat_mkdir_home ("perl/autoload", 0644);
-
- weechat_hook_signal ("dump_data", &weechat_perl_dump_data_cb, NULL);
-
- script_init (weechat_perl_plugin);
- script_auto_load (weechat_perl_plugin, "perl", &weechat_perl_load_cb);
+ script_init (weechat_perl_plugin,
+ &weechat_perl_command_cb, &weechat_perl_dump_data_cb,
+ &weechat_perl_load_cb);
/* init ok */
return WEECHAT_RC_OK;
diff --git a/src/plugins/scripts/python/weechat-python.c b/src/plugins/scripts/python/weechat-python.c
index 81db742d4..bbf01dd09 100644
--- a/src/plugins/scripts/python/weechat-python.c
+++ b/src/plugins/scripts/python/weechat-python.c
@@ -153,7 +153,7 @@ weechat_python_exec (struct t_plugin_script *script,
if (ret_value == NULL)
{
weechat_printf (NULL,
- weechat_gettext ("%s%s: not enough memory for "
+ weechat_gettext ("%s%s: not enough memory in "
"function \"%s\""),
weechat_prefix ("error"), "python", function);
/* PyEval_ReleaseThread (python_current_script->interpreter); */
@@ -211,7 +211,7 @@ weechat_python_output (PyObject *self, PyObject *args)
if (strlen(m) + strlen(python_buffer_output) > sizeof(python_buffer_output))
{
weechat_printf (NULL,
- weechat_gettext ("%s: stdout/stderr : %s%s"),
+ weechat_gettext ("%s: stdout/stderr: %s%s"),
"python", python_buffer_output, m);
python_buffer_output[0] = '\0';
}
@@ -490,11 +490,7 @@ int
weechat_python_command_cb (void *data, struct t_gui_buffer *buffer,
int argc, char **argv, char **argv_eol)
{
- //int handler_found, modifier_found;
char *path_script;
- struct t_plugin_script *ptr_script;
- //struct t_plugin_handler *ptr_handler;
- //struct t_plugin_modifier *ptr_modifier;
/* make C compiler happy */
(void) data;
@@ -502,164 +498,29 @@ weechat_python_command_cb (void *data, struct t_gui_buffer *buffer,
if (argc == 1)
{
- /* list registered Python scripts */
- weechat_printf (NULL, "");
- weechat_printf (NULL,
- weechat_gettext ("Registered %s scripts:"),
- "python");
- if (python_scripts)
- {
- for (ptr_script = python_scripts; ptr_script;
- ptr_script = ptr_script->next_script)
- {
- weechat_printf (NULL,
- weechat_gettext (" %s v%s (%s), by %s, "
- "license %s"),
- ptr_script->name,
- ptr_script->version,
- ptr_script->description,
- ptr_script->author,
- ptr_script->license);
- }
- }
- else
- weechat_printf (NULL, weechat_gettext (" (none)"));
-
- /*
- // list Python message handlers
- plugin->print_server (plugin, "");
- plugin->print_server (plugin, "Python message handlers:");
- handler_found = 0;
- for (ptr_handler = plugin->handlers;
- ptr_handler; ptr_handler = ptr_handler->next_handler)
- {
- if ((ptr_handler->type == PLUGIN_HANDLER_MESSAGE)
- && (ptr_handler->handler_args))
- {
- handler_found = 1;
- plugin->print_server (plugin, " IRC(%s) => Python(%s)",
- ptr_handler->irc_command,
- ptr_handler->handler_args);
- }
- }
- if (!handler_found)
- plugin->print_server (plugin, " (none)");
-
- // list Python command handlers
- plugin->print_server (plugin, "");
- plugin->print_server (plugin, "Python command handlers:");
- handler_found = 0;
- for (ptr_handler = plugin->handlers;
- ptr_handler; ptr_handler = ptr_handler->next_handler)
- {
- if ((ptr_handler->type == PLUGIN_HANDLER_COMMAND)
- && (ptr_handler->handler_args))
- {
- handler_found = 1;
- plugin->print_server (plugin, " /%s => Python(%s)",
- ptr_handler->command,
- ptr_handler->handler_args);
- }
- }
- if (!handler_found)
- plugin->print_server (plugin, " (none)");
-
- // list Python timer handlers
- plugin->print_server (plugin, "");
- plugin->print_server (plugin, "Python timer handlers:");
- handler_found = 0;
- for (ptr_handler = plugin->handlers;
- ptr_handler; ptr_handler = ptr_handler->next_handler)
- {
- if ((ptr_handler->type == PLUGIN_HANDLER_TIMER)
- && (ptr_handler->handler_args))
- {
- handler_found = 1;
- plugin->print_server (plugin, " %d seconds => Python(%s)",
- ptr_handler->interval,
- ptr_handler->handler_args);
- }
- }
- if (!handler_found)
- plugin->print_server (plugin, " (none)");
-
- // list Python keyboard handlers
- plugin->print_server (plugin, "");
- plugin->print_server (plugin, "Python keyboard handlers:");
- handler_found = 0;
- for (ptr_handler = plugin->handlers;
- ptr_handler; ptr_handler = ptr_handler->next_handler)
+ script_display_list (weechat_python_plugin, python_scripts,
+ NULL, 0);
+ }
+ else if (argc == 2)
+ {
+ if (weechat_strcasecmp (argv[1], "list") == 0)
{
- if ((ptr_handler->type == PLUGIN_HANDLER_KEYBOARD)
- && (ptr_handler->handler_args))
- {
- handler_found = 1;
- plugin->print_server (plugin, " Python(%s)",
- ptr_handler->handler_args);
- }
+ script_display_list (weechat_python_plugin, python_scripts,
+ NULL, 0);
}
- if (!handler_found)
- plugin->print_server (plugin, " (none)");
-
- // list Python event handlers
- plugin->print_server (plugin, "");
- plugin->print_server (plugin, "Python event handlers:");
- handler_found = 0;
- for (ptr_handler = plugin->handlers;
- ptr_handler; ptr_handler = ptr_handler->next_handler)
+ else if (weechat_strcasecmp (argv[1], "listfull") == 0)
{
- if ((ptr_handler->type == PLUGIN_HANDLER_EVENT)
- && (ptr_handler->handler_args))
- {
- handler_found = 1;
- plugin->print_server (plugin, " %s => Python(%s)",
- ptr_handler->event,
- ptr_handler->handler_args);
- }
+ script_display_list (weechat_python_plugin, python_scripts,
+ NULL, 1);
}
- if (!handler_found)
- plugin->print_server (plugin, " (none)");
-
- // list Python modifiers
- plugin->print_server (plugin, "");
- plugin->print_server (plugin, "Python modifiers:");
- modifier_found = 0;
- for (ptr_modifier = plugin->modifiers;
- ptr_modifier; ptr_modifier = ptr_modifier->next_modifier)
- {
- modifier_found = 1;
- if (ptr_modifier->type == PLUGIN_MODIFIER_IRC_IN)
- plugin->print_server (plugin, " IRC(%s, %s) => Python(%s)",
- ptr_modifier->command,
- PLUGIN_MODIFIER_IRC_IN_STR,
- ptr_modifier->modifier_args);
- else if (ptr_modifier->type == PLUGIN_MODIFIER_IRC_USER)
- plugin->print_server (plugin, " IRC(%s, %s) => Python(%s)",
- ptr_modifier->command,
- PLUGIN_MODIFIER_IRC_USER_STR,
- ptr_modifier->modifier_args);
- else if (ptr_modifier->type == PLUGIN_MODIFIER_IRC_OUT)
- plugin->print_server (plugin, " IRC(%s, %s) => Python(%s)",
- ptr_modifier->command,
- PLUGIN_MODIFIER_IRC_OUT_STR,
- ptr_modifier->modifier_args);
- }
- if (!modifier_found)
- plugin->print_server (plugin, " (none)");
- */
- }
- else if (argc == 2)
- {
- if (weechat_strcasecmp (argv[1], "autoload") == 0)
+ else if (weechat_strcasecmp (argv[1], "autoload") == 0)
{
- script_auto_load (weechat_python_plugin,
- "python", &weechat_python_load_cb);
+ script_auto_load (weechat_python_plugin, &weechat_python_load_cb);
}
else if (weechat_strcasecmp (argv[1], "reload") == 0)
{
weechat_python_unload_all ();
- script_auto_load (weechat_python_plugin,
- "python", &weechat_python_load_cb);
+ script_auto_load (weechat_python_plugin, &weechat_python_load_cb);
}
else if (weechat_strcasecmp (argv[1], "unload") == 0)
{
@@ -668,11 +529,21 @@ weechat_python_command_cb (void *data, struct t_gui_buffer *buffer,
}
else
{
- if (weechat_strcasecmp (argv[1], "load") == 0)
+ if (weechat_strcasecmp (argv[1], "list") == 0)
+ {
+ script_display_list (weechat_python_plugin, python_scripts,
+ argv_eol[2], 0);
+ }
+ else if (weechat_strcasecmp (argv[1], "listfull") == 0)
+ {
+ script_display_list (weechat_python_plugin, python_scripts,
+ argv_eol[2], 1);
+ }
+ else if (weechat_strcasecmp (argv[1], "load") == 0)
{
/* load Python script */
path_script = script_search_full_name (weechat_python_plugin,
- "python", argv_eol[2]);
+ argv_eol[2]);
weechat_python_load ((path_script) ? path_script : argv_eol[2]);
if (path_script)
free (path_script);
@@ -749,25 +620,9 @@ weechat_plugin_init (struct t_weechat_plugin *plugin)
return WEECHAT_RC_ERROR;
}
- weechat_hook_command ("python",
- weechat_gettext ("list/load/unload Python scripts"),
- weechat_gettext ("[load filename] | [autoload] | "
- "[reload] | [unload [script]]"),
- weechat_gettext ("filename: Python script (file) to "
- "load\n"
- "script: script name to unload\n\n"
- "Without argument, /python command "
- "lists all loaded Python scripts."),
- "load|autoload|reload|unload %f",
- &weechat_python_command_cb, NULL);
-
- weechat_mkdir_home ("python", 0644);
- weechat_mkdir_home ("python/autoload", 0644);
-
- weechat_hook_signal ("dump_data", &weechat_python_dump_data_cb, NULL);
-
- script_init (weechat_python_plugin);
- script_auto_load (weechat_python_plugin, "python", &weechat_python_load_cb);
+ script_init (weechat_python_plugin,
+ &weechat_python_command_cb, &weechat_python_dump_data_cb,
+ &weechat_python_load_cb);
/* init ok */
return WEECHAT_RC_OK;
diff --git a/src/plugins/scripts/ruby/weechat-ruby-api.c b/src/plugins/scripts/ruby/weechat-ruby-api.c
index 03bd324a5..044961b3f 100644
--- a/src/plugins/scripts/ruby/weechat-ruby-api.c
+++ b/src/plugins/scripts/ruby/weechat-ruby-api.c
@@ -21,16 +21,6 @@
#undef _
#include <ruby.h>
-//#include <stdio.h>
-//#include <stdlib.h>
-//#include <string.h>
-//#include <stdarg.h>
-//#include <time.h>
-//#include <sys/socket.h>
-//#include <netinet/in.h>
-//#include <arpa/inet.h>
-//#include <sys/types.h>
-//#include <sys/stat.h>
#include "../../weechat-plugin.h"
#include "../script.h"
diff --git a/src/plugins/scripts/ruby/weechat-ruby.c b/src/plugins/scripts/ruby/weechat-ruby.c
index 167cc4091..07d499447 100644
--- a/src/plugins/scripts/ruby/weechat-ruby.c
+++ b/src/plugins/scripts/ruby/weechat-ruby.c
@@ -21,14 +21,7 @@
#undef _
#include <ruby.h>
-//#include <stdio.h>
-//#include <stdlib.h>
-//#include <string.h>
#include <stdarg.h>
-//#include <time.h>
-//#include <sys/socket.h>
-//#include <netinet/in.h>
-//#include <arpa/inet.h>
#include <sys/types.h>
#include <sys/stat.h>
@@ -239,7 +232,7 @@ weechat_ruby_output (VALUE self, VALUE str)
if (strlen (m) + strlen (ruby_buffer_output) > 0)
{
weechat_printf (NULL,
- weechat_gettext ("%s%s: stdout/stderr : %s%s"),
+ weechat_gettext ("%s%s: stdout/stderr: %s%s"),
weechat_prefix ("error"), "ruby",
ruby_buffer_output, m);
}
@@ -251,7 +244,7 @@ weechat_ruby_output (VALUE self, VALUE str)
if (strlen(m) + strlen(ruby_buffer_output) > sizeof(ruby_buffer_output))
{
weechat_printf (NULL,
- weechat_gettext ("%s%s: stdout/stderr : %s%s"),
+ weechat_gettext ("%s%s: stdout/stderr: %s%s"),
weechat_prefix ("error"), "ruby",
ruby_buffer_output, m);
ruby_buffer_output[0] = '\0';
@@ -344,8 +337,8 @@ weechat_ruby_load (char *filename)
break;
case 3:
weechat_printf (NULL,
- weechat_gettext ("%s%s: unable to find "
- "\"weechat_init\" function "
+ weechat_gettext ("%s%s: function "
+ "\"weechat_init\" is missing "
"in file \"%s\""),
weechat_prefix ("error"), "ruby", filename);
break;
@@ -366,12 +359,13 @@ weechat_ruby_load (char *filename)
return 0;
}
- ruby_retcode = rb_protect_funcall (curModule, rb_intern("weechat_init"), &ruby_error, 0);
+ ruby_retcode = rb_protect_funcall (curModule, rb_intern("weechat_init"),
+ &ruby_error, 0);
if (ruby_error)
{
weechat_printf (NULL,
- weechat_gettext ("%s%s: unable to eval "
+ weechat_gettext ("%s%s: unable to eval function "
"\"weechat_init\" in file \"%s\""),
weechat_prefix ("error"), "ruby", filename);
@@ -493,11 +487,7 @@ int
weechat_ruby_command_cb (void *data, struct t_gui_buffer *buffer,
int argc, char **argv, char **argv_eol)
{
- //int handler_found, modifier_found;
char *path_script;
- struct t_plugin_script *ptr_script;
- //t_plugin_handler *ptr_handler;
- //t_plugin_modifier *ptr_modifier;
/* make C compiler happy */
(void) data;
@@ -505,164 +495,29 @@ weechat_ruby_command_cb (void *data, struct t_gui_buffer *buffer,
if (argc == 1)
{
- /* list registered Ruby scripts */
- weechat_printf (NULL, "");
- weechat_printf (NULL,
- weechat_gettext ("Registered %s scripts:"),
- "ruby");
- if (ruby_scripts)
- {
- for (ptr_script = ruby_scripts; ptr_script;
- ptr_script = ptr_script->next_script)
- {
- weechat_printf (NULL,
- weechat_gettext (" %s v%s (%s), by %s, "
- "license %s"),
- ptr_script->name,
- ptr_script->version,
- ptr_script->description,
- ptr_script->author,
- ptr_script->license);
- }
- }
- else
- weechat_printf (NULL, weechat_gettext (" (none)"));
-
- /*
- // list Ruby message handlers
- plugin->print_server (plugin, "");
- plugin->print_server (plugin, "Ruby message handlers:");
- handler_found = 0;
- for (ptr_handler = plugin->handlers;
- ptr_handler; ptr_handler = ptr_handler->next_handler)
- {
- if ((ptr_handler->type == PLUGIN_HANDLER_MESSAGE)
- && (ptr_handler->handler_args))
- {
- handler_found = 1;
- plugin->print_server (plugin, " IRC(%s) => Ruby(%s)",
- ptr_handler->irc_command,
- ptr_handler->handler_args);
- }
- }
- if (!handler_found)
- plugin->print_server (plugin, " (none)");
-
- // list Ruby command handlers
- plugin->print_server (plugin, "");
- plugin->print_server (plugin, "Ruby command handlers:");
- handler_found = 0;
- for (ptr_handler = plugin->handlers;
- ptr_handler; ptr_handler = ptr_handler->next_handler)
- {
- if ((ptr_handler->type == PLUGIN_HANDLER_COMMAND)
- && (ptr_handler->handler_args))
- {
- handler_found = 1;
- plugin->print_server (plugin, " /%s => Ruby(%s)",
- ptr_handler->command,
- ptr_handler->handler_args);
- }
- }
- if (!handler_found)
- plugin->print_server (plugin, " (none)");
-
- // list Ruby timer handlers
- plugin->print_server (plugin, "");
- plugin->print_server (plugin, "Ruby timer handlers:");
- handler_found = 0;
- for (ptr_handler = plugin->handlers;
- ptr_handler; ptr_handler = ptr_handler->next_handler)
- {
- if ((ptr_handler->type == PLUGIN_HANDLER_TIMER)
- && (ptr_handler->handler_args))
- {
- handler_found = 1;
- plugin->print_server (plugin, " %d seconds => Ruby(%s)",
- ptr_handler->interval,
- ptr_handler->handler_args);
- }
- }
- if (!handler_found)
- plugin->print_server (plugin, " (none)");
-
- // list Ruby keyboard handlers
- plugin->print_server (plugin, "");
- plugin->print_server (plugin, "Ruby keyboard handlers:");
- handler_found = 0;
- for (ptr_handler = plugin->handlers;
- ptr_handler; ptr_handler = ptr_handler->next_handler)
- {
- if ((ptr_handler->type == PLUGIN_HANDLER_KEYBOARD)
- && (ptr_handler->handler_args))
- {
- handler_found = 1;
- plugin->print_server (plugin, " Ruby(%s)",
- ptr_handler->handler_args);
- }
- }
- if (!handler_found)
- plugin->print_server (plugin, " (none)");
-
- // list Ruby event handlers
- plugin->print_server (plugin, "");
- plugin->print_server (plugin, "Ruby event handlers:");
- handler_found = 0;
- for (ptr_handler = plugin->handlers;
- ptr_handler; ptr_handler = ptr_handler->next_handler)
+ script_display_list (weechat_ruby_plugin, ruby_scripts,
+ NULL, 0);
+ }
+ else if (argc == 2)
+ {
+ if (weechat_strcasecmp (argv[1], "list") == 0)
{
- if ((ptr_handler->type == PLUGIN_HANDLER_EVENT)
- && (ptr_handler->handler_args))
- {
- handler_found = 1;
- plugin->print_server (plugin, " %s => Ruby(%s)",
- ptr_handler->event,
- ptr_handler->handler_args);
- }
+ script_display_list (weechat_ruby_plugin, ruby_scripts,
+ NULL, 0);
}
- if (!handler_found)
- plugin->print_server (plugin, " (none)");
-
- // list Ruby modifiers
- plugin->print_server (plugin, "");
- plugin->print_server (plugin, "Ruby modifiers:");
- modifier_found = 0;
- for (ptr_modifier = plugin->modifiers;
- ptr_modifier; ptr_modifier = ptr_modifier->next_modifier)
+ else if (weechat_strcasecmp (argv[1], "listfull") == 0)
{
- modifier_found = 1;
- if (ptr_modifier->type == PLUGIN_MODIFIER_IRC_IN)
- plugin->print_server (plugin, " IRC(%s, %s) => Ruby(%s)",
- ptr_modifier->command,
- PLUGIN_MODIFIER_IRC_IN_STR,
- ptr_modifier->modifier_args);
- else if (ptr_modifier->type == PLUGIN_MODIFIER_IRC_USER)
- plugin->print_server (plugin, " IRC(%s, %s) => Ruby(%s)",
- ptr_modifier->command,
- PLUGIN_MODIFIER_IRC_USER_STR,
- ptr_modifier->modifier_args);
- else if (ptr_modifier->type == PLUGIN_MODIFIER_IRC_OUT)
- plugin->print_server (plugin, " IRC(%s, %s) => Ruby(%s)",
- ptr_modifier->command,
- PLUGIN_MODIFIER_IRC_OUT_STR,
- ptr_modifier->modifier_args);
+ script_display_list (weechat_ruby_plugin, ruby_scripts,
+ NULL, 1);
}
- if (!modifier_found)
- plugin->print_server (plugin, " (none)");
- */
- }
- else if (argc == 2)
- {
- if (weechat_strcasecmp (argv[1], "autoload") == 0)
+ else if (weechat_strcasecmp (argv[1], "autoload") == 0)
{
- script_auto_load (weechat_ruby_plugin,
- "ruby", &weechat_ruby_load_cb);
+ script_auto_load (weechat_ruby_plugin, &weechat_ruby_load_cb);
}
else if (weechat_strcasecmp (argv[1], "reload") == 0)
{
weechat_ruby_unload_all ();
- script_auto_load (weechat_ruby_plugin,
- "ruby", &weechat_ruby_load_cb);
+ script_auto_load (weechat_ruby_plugin, &weechat_ruby_load_cb);
}
else if (weechat_strcasecmp (argv[1], "unload") == 0)
{
@@ -671,11 +526,21 @@ weechat_ruby_command_cb (void *data, struct t_gui_buffer *buffer,
}
else
{
- if (weechat_strcasecmp (argv[1], "load") == 0)
+ if (weechat_strcasecmp (argv[1], "list") == 0)
+ {
+ script_display_list (weechat_ruby_plugin, ruby_scripts,
+ argv_eol[2], 0);
+ }
+ else if (weechat_strcasecmp (argv[1], "listfull") == 0)
+ {
+ script_display_list (weechat_ruby_plugin, ruby_scripts,
+ argv_eol[2], 1);
+ }
+ else if (weechat_strcasecmp (argv[1], "load") == 0)
{
/* load Ruby script */
path_script = script_search_full_name (weechat_ruby_plugin,
- "ruby", argv_eol[2]);
+ argv_eol[2]);
weechat_ruby_load ((path_script) ? path_script : argv_eol[2]);
if (path_script)
free (path_script);
@@ -793,7 +658,7 @@ weechat_plugin_init (struct t_weechat_plugin *plugin)
{
VALUE ruby_error_info = rb_inspect(ruby_errinfo);
weechat_printf (NULL,
- weechat_gettext ("%s%s: unable to eval weechat ruby "
+ weechat_gettext ("%s%s: unable to eval WeeChat ruby "
"internal code"),
weechat_prefix ("error"), "ruby");
weechat_printf (NULL,
@@ -803,25 +668,9 @@ weechat_plugin_init (struct t_weechat_plugin *plugin)
return WEECHAT_RC_ERROR;
}
- weechat_hook_command ("ruby",
- weechat_gettext ("list/load/unload Ruby scripts"),
- weechat_gettext ("[load filename] | [autoload] | "
- "[reload] | [unload [script]]"),
- weechat_gettext ("filename: Ruby script (file) to "
- "load\n"
- "script: script name to unload\n\n"
- "Without argument, /ruby command "
- "lists all loaded Ruby scripts."),
- "load|autoload|reload|unload %f",
- &weechat_ruby_command_cb, NULL);
-
- weechat_mkdir_home ("ruby", 0644);
- weechat_mkdir_home ("ruby/autoload", 0644);
-
- weechat_hook_signal ("dump_data", &weechat_ruby_dump_data_cb, NULL);
-
- script_init (weechat_ruby_plugin);
- script_auto_load (weechat_ruby_plugin, "ruby", &weechat_ruby_load_cb);
+ script_init (weechat_ruby_plugin,
+ &weechat_ruby_command_cb, &weechat_ruby_dump_data_cb,
+ &weechat_ruby_load_cb);
/* init ok */
return WEECHAT_RC_OK;
diff --git a/src/plugins/scripts/script.c b/src/plugins/scripts/script.c
index bfd848ca7..b864e6e83 100644
--- a/src/plugins/scripts/script.c
+++ b/src/plugins/scripts/script.c
@@ -80,9 +80,17 @@ script_config_cb (void *data, char *type, char *option, char *value)
*/
void
-script_init (struct t_weechat_plugin *weechat_plugin)
+script_init (struct t_weechat_plugin *weechat_plugin,
+ int (*callback_command)(void *data,
+ struct t_gui_buffer *buffer,
+ int argc, char **argv,
+ char **argv_eol),
+ int (*callback_signal_dump)(void *data, char *signal,
+ char *type_data,
+ void *signal_data),
+ int (*callback_load_file)(void *data, char *filename))
{
- char *option;
+ char *string;
int length;
/* read script configuration */
@@ -90,14 +98,45 @@ script_init (struct t_weechat_plugin *weechat_plugin)
/* add hook for config option */
length = strlen (weechat_plugin->name) + 32;
- option= (char *)malloc (length);
- if (option)
+ string = (char *)malloc (length);
+ if (string)
{
- snprintf (option, length - 1, "%s.%s",
+ snprintf (string, length, "%s.%s",
weechat_plugin->name, SCRIPT_OPTION_CHECK_LICENSE);
- weechat_hook_config ("plugin", option,
+ weechat_hook_config ("plugin", string,
&script_config_cb, weechat_plugin);
+ free (string);
+ }
+
+ /* create directories in WeeChat home */
+ weechat_mkdir_home (weechat_plugin->name, 0644);
+ length = strlen (weechat_plugin->name) + strlen ("/autoload") + 1;
+ string = (char *)malloc (length);
+ if (string)
+ {
+ snprintf (string, length, "%s/autoload", weechat_plugin->name);
+ weechat_mkdir_home (string, 0644);
+ free (string);
}
+
+ /* add command */
+ weechat_hook_command (weechat_plugin->name,
+ _("list/load/unload scripts"),
+ _("[list [name]] | [listfull [name]] "
+ "[load filename] | [autoload] | "
+ "[reload] | [unload [name]]"),
+ _("filename: script (file) to load\n"
+ "name: a script name\n\n"
+ "Without argument, this command "
+ "lists all loaded scripts."),
+ "list|listfull|load|autoload|reload|unload %f",
+ callback_command, NULL);
+
+ /* add signal for "dump_data" */
+ weechat_hook_signal ("dump_data", callback_signal_dump, NULL);
+
+ /* autoload scripts */
+ script_auto_load (weechat_plugin, callback_load_file);
}
/*
@@ -144,7 +183,7 @@ script_string_to_pointer (char *pointer_str)
void
script_auto_load (struct t_weechat_plugin *weechat_plugin,
- char *language, int (*callback)(void *data, char *filename))
+ int (*callback)(void *data, char *filename))
{
char *dir_home, *dir_name;
int dir_length;
@@ -153,12 +192,13 @@ script_auto_load (struct t_weechat_plugin *weechat_plugin,
dir_home = weechat_info_get ("weechat_dir");
if (!dir_home)
return;
- dir_length = strlen (dir_home) + strlen (language) + 16;
+ dir_length = strlen (dir_home) + strlen (weechat_plugin->name) + 16;
dir_name = (char *)malloc (dir_length * sizeof (char));
if (!dir_name)
return;
- snprintf (dir_name, dir_length, "%s/%s/autoload", dir_home, language);
+ snprintf (dir_name, dir_length,
+ "%s/%s/autoload", dir_home, weechat_plugin->name);
weechat_exec_on_files (dir_name, NULL, callback);
free (dir_name);
@@ -191,7 +231,7 @@ script_search (struct t_weechat_plugin *weechat_plugin,
char *
script_search_full_name (struct t_weechat_plugin *weechat_plugin,
- char *language, char *filename)
+ char *filename)
{
char *final_name, *dir_home, *dir_system;
int length;
@@ -216,24 +256,27 @@ script_search_full_name (struct t_weechat_plugin *weechat_plugin,
if (dir_home)
{
/* try WeeChat user's autoload dir */
- length = strlen (dir_home) + strlen (language) + 8 + strlen (filename) + 16;
+ length = strlen (dir_home) + strlen (weechat_plugin->name) + 8 +
+ strlen (filename) + 16;
final_name = (char *)malloc (length);
if (final_name)
{
snprintf (final_name, length,
- "%s/%s/autoload/%s", dir_home, language, filename);
+ "%s/%s/autoload/%s",
+ dir_home, weechat_plugin->name, filename);
if ((stat (final_name, &st) == 0) && (st.st_size > 0))
return final_name;
free (final_name);
}
/* try WeeChat language user's dir */
- length = strlen (dir_home) + strlen (language) + strlen (filename) + 16;
+ length = strlen (dir_home) + strlen (weechat_plugin->name) +
+ strlen (filename) + 16;
final_name = (char *)malloc (length);
if (final_name)
{
snprintf (final_name, length,
- "%s/%s/%s", dir_home, language, filename);
+ "%s/%s/%s", dir_home, weechat_plugin->name, filename);
if ((stat (final_name, &st) == 0) && (st.st_size > 0))
return final_name;
free (final_name);
@@ -256,12 +299,13 @@ script_search_full_name (struct t_weechat_plugin *weechat_plugin,
dir_system = weechat_info_get ("weechat_sharedir");
if (dir_system)
{
- length = strlen (dir_system) + strlen (dir_system) + strlen (filename) + 16;
+ length = strlen (dir_system) + strlen (weechat_plugin->name) +
+ strlen (filename) + 16;
final_name = (char *)malloc (length);
if (final_name)
{
snprintf (final_name,length,
- "%s/%s/%s", dir_system, language, filename);
+ "%s/%s/%s", dir_system, weechat_plugin->name, filename);
if ((stat (final_name, &st) == 0) && (st.st_size > 0))
return final_name;
free (final_name);
@@ -376,6 +420,53 @@ script_remove (struct t_weechat_plugin *weechat_plugin,
}
/*
+ * script_display_list: print list of scripts
+ */
+
+void
+script_display_list (struct t_weechat_plugin *weechat_plugin,
+ struct t_plugin_script *scripts,
+ char *name, int full)
+{
+ struct t_plugin_script *ptr_script;
+
+ weechat_printf (NULL, "");
+ weechat_printf (NULL,
+ /* TRANSLATORS: %s is language (for example "perl") */
+ _("%s scripts loaded:"),
+ weechat_plugin->name);
+ if (scripts)
+ {
+ for (ptr_script = scripts; ptr_script;
+ ptr_script = ptr_script->next_script)
+ {
+ if (!name || (weechat_strcasestr (ptr_script->name, name)))
+ {
+ weechat_printf (NULL,
+ " %s%s%s v%s - %s",
+ weechat_color ("color_chat_buffer"),
+ ptr_script->name,
+ weechat_color ("color_chat"),
+ ptr_script->version,
+ ptr_script->description);
+ if (full)
+ {
+ weechat_printf (NULL,
+ _(" file: %s"),
+ ptr_script->filename);
+ weechat_printf (NULL,
+ _(" written by \"%s\", license: %s"),
+ ptr_script->author,
+ ptr_script->license);
+ }
+ }
+ }
+ }
+ else
+ weechat_printf (NULL, _(" (none)"));
+}
+
+/*
* script_print_log: print script infos in log (usually for crash dump)
*/
diff --git a/src/plugins/scripts/script.h b/src/plugins/scripts/script.h
index 0891ac4da..59ee51eef 100644
--- a/src/plugins/scripts/script.h
+++ b/src/plugins/scripts/script.h
@@ -56,17 +56,24 @@ struct t_plugin_script
struct t_plugin_script *next_script; /* link to next script */
};
-extern void script_init (struct t_weechat_plugin *weechat_plugin);
+extern void script_init (struct t_weechat_plugin *weechat_plugin,
+ int (*callback_command)(void *data,
+ struct t_gui_buffer *buffer,
+ int argc, char **argv,
+ char **argv_eol),
+ int (*callback_signal_dump)(void *data, char *signal,
+ char *type_data,
+ void *signal_data),
+ int (*callback_load_file)(void *data, char *filename));
extern char *script_pointer_to_string (void *pointer);
extern void *script_string_to_pointer (char *pointer_str);
extern void script_auto_load (struct t_weechat_plugin *weechat_plugin,
- char *language,
int (*callback)(void *data, char *filename));
extern struct t_plugin_script *script_search (struct t_weechat_plugin *weechat_plugin,
struct t_plugin_script *scripts,
char *name);
extern char *script_search_full_name (struct t_weechat_plugin *weechat_plugin,
- char *language, char *filename);
+ char *filename);
extern struct t_plugin_script *script_add (struct t_weechat_plugin *weechat_plugin,
struct t_plugin_script **scripts,
char *filename, char *name,
@@ -76,6 +83,9 @@ extern struct t_plugin_script *script_add (struct t_weechat_plugin *weechat_plug
extern void script_remove (struct t_weechat_plugin *weechat_plugin,
struct t_plugin_script **scripts,
struct t_plugin_script *script);
+extern void script_display_list (struct t_weechat_plugin *weechat_plugin,
+ struct t_plugin_script *scripts,
+ char *name, int full);
extern void script_print_log (struct t_weechat_plugin *weechat_plugin,
struct t_plugin_script *scripts);