mirror of
https://github.com/weechat/weechat.git
synced 2026-06-26 12:56:37 +02:00
script: add info "script_loaded"
This commit is contained in:
@@ -25,6 +25,7 @@ New features::
|
||||
* irc: add server option "autojoin_delay" (delay before autojoin), use option "command_delay" before execution of the command (issue #862)
|
||||
* relay: add "api" protocol (HTTP REST API), add option relay.look.display_clients, change option type relay.look.auto_open_buffer to string, rename option relay.weechat.commands to relay.network.commands, add option relay.network.time_window (issue #2066)
|
||||
* relay: add support of websocket extension "permessage-deflate" (issue #1549)
|
||||
* script: add info "script_loaded"
|
||||
|
||||
Bug fixes::
|
||||
|
||||
|
||||
@@ -21,7 +21,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2024-02-19 18:27+0100\n"
|
||||
"POT-Creation-Date: 2024-02-19 18:30+0100\n"
|
||||
"PO-Revision-Date: 2024-02-17 10:07+0100\n"
|
||||
"Last-Translator: Ondřej Súkup <mimi.vx@gmail.com>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
@@ -14825,6 +14825,14 @@ msgstr ""
|
||||
msgid "URL for file with list of scripts"
|
||||
msgstr "URL souboru s seznamem skriptů"
|
||||
|
||||
#, fuzzy
|
||||
msgid "1 if script is loaded"
|
||||
msgstr "načteny %s skripty:"
|
||||
|
||||
#, fuzzy
|
||||
msgid "script name with extension"
|
||||
msgstr "seznam skriptů"
|
||||
|
||||
#, fuzzy
|
||||
msgid "script name with extension (wildcard \"*\" is allowed) (optional)"
|
||||
msgstr "jméno serveru (zástupný znak \"*\" je povolen) (volitelné)"
|
||||
|
||||
@@ -26,7 +26,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2024-02-19 18:27+0100\n"
|
||||
"POT-Creation-Date: 2024-02-19 18:30+0100\n"
|
||||
"PO-Revision-Date: 2024-02-17 17:31+0100\n"
|
||||
"Last-Translator: Nils Görs <weechatter@arcor.de>\n"
|
||||
"Language-Team: German <kde-i18n-de@kde.org>\n"
|
||||
@@ -16357,6 +16357,16 @@ msgstr ""
|
||||
msgid "URL for file with list of scripts"
|
||||
msgstr "URL für Datei mit der Auflistung aller Skripten"
|
||||
|
||||
#, fuzzy
|
||||
#| msgid "No scripts loaded"
|
||||
msgid "1 if script is loaded"
|
||||
msgstr "Keine Skripten geladen"
|
||||
|
||||
#, fuzzy
|
||||
#| msgid "list of script extensions"
|
||||
msgid "script name with extension"
|
||||
msgstr "Liste der Skripterweiterungen"
|
||||
|
||||
msgid "script name with extension (wildcard \"*\" is allowed) (optional)"
|
||||
msgstr ""
|
||||
"Name des Skriptes, mit Dateierweiterung (Platzhalter \"*\" kann verwendet "
|
||||
|
||||
@@ -22,7 +22,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2024-02-19 18:27+0100\n"
|
||||
"POT-Creation-Date: 2024-02-19 18:30+0100\n"
|
||||
"PO-Revision-Date: 2024-02-17 10:07+0100\n"
|
||||
"Last-Translator: Santiago Forero <santiago@forero.xyz>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
@@ -15113,6 +15113,14 @@ msgstr ""
|
||||
msgid "URL for file with list of scripts"
|
||||
msgstr "%s%s: error al leer la lista de scripts"
|
||||
|
||||
#, fuzzy
|
||||
msgid "1 if script is loaded"
|
||||
msgstr "scripts en %s cargados:"
|
||||
|
||||
#, fuzzy
|
||||
msgid "script name with extension"
|
||||
msgstr "lista de scripts"
|
||||
|
||||
#, fuzzy
|
||||
msgid "script name with extension (wildcard \"*\" is allowed) (optional)"
|
||||
msgstr ""
|
||||
|
||||
@@ -21,8 +21,8 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2024-02-19 18:27+0100\n"
|
||||
"PO-Revision-Date: 2024-02-19 18:28+0100\n"
|
||||
"POT-Creation-Date: 2024-02-19 18:30+0100\n"
|
||||
"PO-Revision-Date: 2024-02-19 18:30+0100\n"
|
||||
"Last-Translator: Sébastien Helleu <flashcode@flashtux.org>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
"Language: fr\n"
|
||||
@@ -16021,6 +16021,12 @@ msgstr ""
|
||||
msgid "URL for file with list of scripts"
|
||||
msgstr "URL pour le fichier avec la liste des scripts"
|
||||
|
||||
msgid "1 if script is loaded"
|
||||
msgstr "1 si le script est chargé"
|
||||
|
||||
msgid "script name with extension"
|
||||
msgstr "nom du script avec l'extension"
|
||||
|
||||
msgid "script name with extension (wildcard \"*\" is allowed) (optional)"
|
||||
msgstr ""
|
||||
"nom du script avec extension (le caractère joker \"*\" est autorisé) "
|
||||
|
||||
@@ -20,7 +20,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2024-02-19 18:27+0100\n"
|
||||
"POT-Creation-Date: 2024-02-19 18:30+0100\n"
|
||||
"PO-Revision-Date: 2023-11-29 09:59+0100\n"
|
||||
"Last-Translator: Andras Voroskoi <voroskoi@frugalware.org>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
@@ -14236,6 +14236,14 @@ msgstr ""
|
||||
msgid "URL for file with list of scripts"
|
||||
msgstr "%s adatküldési hiba az IRC szerveren\n"
|
||||
|
||||
#, fuzzy
|
||||
msgid "1 if script is loaded"
|
||||
msgstr "FIFO cső bezárva\n"
|
||||
|
||||
#, fuzzy
|
||||
msgid "script name with extension"
|
||||
msgstr "Aliaszok listája:\n"
|
||||
|
||||
msgid "script name with extension (wildcard \"*\" is allowed) (optional)"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -20,7 +20,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2024-02-19 18:27+0100\n"
|
||||
"POT-Creation-Date: 2024-02-19 18:30+0100\n"
|
||||
"PO-Revision-Date: 2024-02-17 10:07+0100\n"
|
||||
"Last-Translator: Esteban I. Ruiz Moreno <exio4.com@gmail.com>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
@@ -15168,6 +15168,14 @@ msgstr ""
|
||||
msgid "URL for file with list of scripts"
|
||||
msgstr "%s%s: errore durante la lettura dell'elenco degli script"
|
||||
|
||||
#, fuzzy
|
||||
msgid "1 if script is loaded"
|
||||
msgstr "script %s caricati:"
|
||||
|
||||
#, fuzzy
|
||||
msgid "script name with extension"
|
||||
msgstr "elenco degli script"
|
||||
|
||||
#, fuzzy
|
||||
msgid "script name with extension (wildcard \"*\" is allowed) (optional)"
|
||||
msgstr ""
|
||||
|
||||
@@ -20,7 +20,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2024-02-19 18:27+0100\n"
|
||||
"POT-Creation-Date: 2024-02-19 18:30+0100\n"
|
||||
"PO-Revision-Date: 2024-02-17 10:07+0100\n"
|
||||
"Last-Translator: AYANOKOUZI, Ryuunosuke <i38w7i3@yahoo.co.jp>\n"
|
||||
"Language-Team: Japanese <https://github.com/l/weechat/tree/master/"
|
||||
@@ -15623,6 +15623,15 @@ msgstr ""
|
||||
msgid "URL for file with list of scripts"
|
||||
msgstr "スクリプトのリストを含むファイルの URL"
|
||||
|
||||
#, fuzzy
|
||||
msgid "1 if script is loaded"
|
||||
msgstr "ロードされた %s スクリプト:"
|
||||
|
||||
#, fuzzy
|
||||
#| msgid "list of script extensions"
|
||||
msgid "script name with extension"
|
||||
msgstr "スクリプトの拡張子のリスト"
|
||||
|
||||
msgid "script name with extension (wildcard \"*\" is allowed) (optional)"
|
||||
msgstr ""
|
||||
"拡張子を含めたスクリプト名 (ワイルドカード \"*\" を使うことができます) (任意)"
|
||||
|
||||
@@ -22,7 +22,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2024-02-19 18:27+0100\n"
|
||||
"POT-Creation-Date: 2024-02-19 18:30+0100\n"
|
||||
"PO-Revision-Date: 2024-02-17 10:07+0100\n"
|
||||
"Last-Translator: Krzysztof Korościk <soltys@soltys.info>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
@@ -15599,6 +15599,16 @@ msgstr ""
|
||||
msgid "URL for file with list of scripts"
|
||||
msgstr "Adres URL pliku z listą skryptów"
|
||||
|
||||
#, fuzzy
|
||||
#| msgid "No scripts loaded"
|
||||
msgid "1 if script is loaded"
|
||||
msgstr "Nie załadowano żadnego skryptu"
|
||||
|
||||
#, fuzzy
|
||||
#| msgid "list of script extensions"
|
||||
msgid "script name with extension"
|
||||
msgstr "lista rozszerzeń skryptów"
|
||||
|
||||
msgid "script name with extension (wildcard \"*\" is allowed) (optional)"
|
||||
msgstr ""
|
||||
"nazwa skryptu z rozszerzeniem (wildcard \"*\" jest dozwolony) (opcjonalne)\""
|
||||
|
||||
@@ -20,7 +20,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2024-02-19 18:27+0100\n"
|
||||
"POT-Creation-Date: 2024-02-19 18:30+0100\n"
|
||||
"PO-Revision-Date: 2024-02-17 10:07+0100\n"
|
||||
"Last-Translator: Vasco Almeida <vascomalmeida@sapo.pt>\n"
|
||||
"Language-Team: Portuguese <>\n"
|
||||
@@ -15545,6 +15545,15 @@ msgstr ""
|
||||
msgid "URL for file with list of scripts"
|
||||
msgstr "%s%s: erro ao ler a lista de scripts"
|
||||
|
||||
#, fuzzy
|
||||
msgid "1 if script is loaded"
|
||||
msgstr "scripts %s carregados:"
|
||||
|
||||
#, fuzzy
|
||||
#| msgid "list of script extensions"
|
||||
msgid "script name with extension"
|
||||
msgstr "lista de extensões de script"
|
||||
|
||||
msgid "script name with extension (wildcard \"*\" is allowed) (optional)"
|
||||
msgstr ""
|
||||
"nome do script com extensão (o caráter universal \"*\" é permitido) "
|
||||
|
||||
+9
-1
@@ -21,7 +21,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2024-02-19 18:27+0100\n"
|
||||
"POT-Creation-Date: 2024-02-19 18:30+0100\n"
|
||||
"PO-Revision-Date: 2024-02-17 10:07+0100\n"
|
||||
"Last-Translator: Érico Nogueira <ericonr@disroot.org>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
@@ -14657,6 +14657,14 @@ msgstr ""
|
||||
msgid "URL for file with list of scripts"
|
||||
msgstr "%s%s: erro ao criar transferência"
|
||||
|
||||
#, fuzzy
|
||||
msgid "1 if script is loaded"
|
||||
msgstr "scripts %s carregados:"
|
||||
|
||||
#, fuzzy
|
||||
msgid "script name with extension"
|
||||
msgstr "list de scripts"
|
||||
|
||||
#, fuzzy
|
||||
msgid "script name with extension (wildcard \"*\" is allowed) (optional)"
|
||||
msgstr ""
|
||||
|
||||
@@ -21,7 +21,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2024-02-19 18:27+0100\n"
|
||||
"POT-Creation-Date: 2024-02-19 18:30+0100\n"
|
||||
"PO-Revision-Date: 2023-11-29 09:59+0100\n"
|
||||
"Last-Translator: Aleksey V Zapparov AKA ixti <ixti@member.fsf.org>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
@@ -14288,6 +14288,14 @@ msgstr ""
|
||||
msgid "URL for file with list of scripts"
|
||||
msgstr "%s ошибка при отправке данных IRC серверу\n"
|
||||
|
||||
#, fuzzy
|
||||
msgid "1 if script is loaded"
|
||||
msgstr "FIFO pipe закрыт\n"
|
||||
|
||||
#, fuzzy
|
||||
msgid "script name with extension"
|
||||
msgstr "Список сокращений:\n"
|
||||
|
||||
msgid "script name with extension (wildcard \"*\" is allowed) (optional)"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -20,7 +20,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2024-02-19 18:27+0100\n"
|
||||
"POT-Creation-Date: 2024-02-19 18:30+0100\n"
|
||||
"PO-Revision-Date: 2024-02-17 10:08+0100\n"
|
||||
"Last-Translator: Ivan Pešić <ivan.pesic@gmail.com>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
@@ -15565,6 +15565,16 @@ msgstr ""
|
||||
msgid "URL for file with list of scripts"
|
||||
msgstr "URL фајла са листом скрипти"
|
||||
|
||||
#, fuzzy
|
||||
#| msgid "No scripts loaded"
|
||||
msgid "1 if script is loaded"
|
||||
msgstr "Није учитана ниједна скрипта"
|
||||
|
||||
#, fuzzy
|
||||
#| msgid "list of script extensions"
|
||||
msgid "script name with extension"
|
||||
msgstr "листа скрипт екстензија"
|
||||
|
||||
msgid "script name with extension (wildcard \"*\" is allowed) (optional)"
|
||||
msgstr "име скрипте са екстензијом (дозвољен је џокер „*”) (није обавезно)"
|
||||
|
||||
|
||||
@@ -20,7 +20,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2024-02-19 18:27+0100\n"
|
||||
"POT-Creation-Date: 2024-02-19 18:30+0100\n"
|
||||
"PO-Revision-Date: 2024-02-17 10:08+0100\n"
|
||||
"Last-Translator: Emir SARI <emir_sari@icloud.com>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
@@ -15821,6 +15821,16 @@ msgstr ""
|
||||
msgid "URL for file with list of scripts"
|
||||
msgstr "Betik listeli dosya URL'si"
|
||||
|
||||
#, fuzzy
|
||||
#| msgid "No scripts loaded"
|
||||
msgid "1 if script is loaded"
|
||||
msgstr "Hiçbir betik yüklenmedi"
|
||||
|
||||
#, fuzzy
|
||||
#| msgid "list of script extensions"
|
||||
msgid "script name with extension"
|
||||
msgstr "betik uzantılarının listesi"
|
||||
|
||||
msgid "script name with extension (wildcard \"*\" is allowed) (optional)"
|
||||
msgstr "betik adı, uzantı ile (\"*\" jokerine izin verilir) (isteğe bağlı)"
|
||||
|
||||
|
||||
+7
-1
@@ -21,7 +21,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2024-02-19 18:27+0100\n"
|
||||
"POT-Creation-Date: 2024-02-19 18:30+0100\n"
|
||||
"PO-Revision-Date: 2014-08-16 10:27+0200\n"
|
||||
"Last-Translator: Sébastien Helleu <flashcode@flashtux.org>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
@@ -13030,6 +13030,12 @@ msgstr ""
|
||||
msgid "URL for file with list of scripts"
|
||||
msgstr ""
|
||||
|
||||
msgid "1 if script is loaded"
|
||||
msgstr ""
|
||||
|
||||
msgid "script name with extension"
|
||||
msgstr ""
|
||||
|
||||
msgid "script name with extension (wildcard \"*\" is allowed) (optional)"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -28,6 +28,57 @@
|
||||
#include "script-repo.h"
|
||||
|
||||
|
||||
/*
|
||||
* Returns script info "script_loaded".
|
||||
*/
|
||||
|
||||
char *
|
||||
script_info_info_script_loaded_cb (const void *pointer, void *data,
|
||||
const char *info_name,
|
||||
const char *arguments)
|
||||
{
|
||||
int i, length;
|
||||
char hdata_name[128];
|
||||
const char *ptr_name;
|
||||
struct t_hdata *hdata;
|
||||
void *ptr_script;
|
||||
|
||||
/* make C compiler happy */
|
||||
(void) pointer;
|
||||
(void) data;
|
||||
(void) info_name;
|
||||
|
||||
if (!arguments || !arguments[0])
|
||||
return NULL;
|
||||
|
||||
for (i = 0; i < SCRIPT_NUM_LANGUAGES; i++)
|
||||
{
|
||||
snprintf (hdata_name, sizeof (hdata_name),
|
||||
"%s_script", script_language[i]);
|
||||
hdata = weechat_hdata_get (hdata_name);
|
||||
ptr_script = weechat_hdata_get_list (hdata, "scripts");
|
||||
while (ptr_script)
|
||||
{
|
||||
ptr_name = weechat_hdata_string (hdata, ptr_script, "name");
|
||||
if (ptr_name)
|
||||
{
|
||||
length = strlen (ptr_name);
|
||||
if ((strncmp (arguments, ptr_name, length) == 0)
|
||||
&& (arguments[length] == '.')
|
||||
&& (strcmp (arguments + length + 1, script_extension[i]) == 0))
|
||||
{
|
||||
/* script loaded */
|
||||
return strdup ("1");
|
||||
}
|
||||
}
|
||||
ptr_script = weechat_hdata_move (hdata, ptr_script, 1);
|
||||
}
|
||||
}
|
||||
|
||||
/* script not loaded */
|
||||
return NULL;
|
||||
}
|
||||
|
||||
/*
|
||||
* Returns script infolist "script_script".
|
||||
*/
|
||||
@@ -93,6 +144,13 @@ script_info_infolist_script_script_cb (const void *pointer, void *data,
|
||||
void
|
||||
script_info_init ()
|
||||
{
|
||||
/* info hooks */
|
||||
weechat_hook_info (
|
||||
"script_loaded",
|
||||
N_("1 if script is loaded"),
|
||||
N_("script name with extension"),
|
||||
&script_info_info_script_loaded_cb, NULL, NULL);
|
||||
|
||||
/* infolist hooks */
|
||||
weechat_hook_infolist (
|
||||
"script_script",
|
||||
|
||||
Reference in New Issue
Block a user