diff options
-rw-r--r-- | ChangeLog.adoc | 1 | ||||
-rw-r--r-- | po/cs.po | 27 | ||||
-rw-r--r-- | po/de.po | 139 | ||||
-rw-r--r-- | po/es.po | 27 | ||||
-rw-r--r-- | po/fr.po | 36 | ||||
-rw-r--r-- | po/hu.po | 26 | ||||
-rw-r--r-- | po/it.po | 27 | ||||
-rw-r--r-- | po/ja.po | 40 | ||||
-rw-r--r-- | po/pl.po | 139 | ||||
-rw-r--r-- | po/pt.po | 40 | ||||
-rw-r--r-- | po/pt_BR.po | 27 | ||||
-rw-r--r-- | po/ru.po | 26 | ||||
-rw-r--r-- | po/sr.po | 139 | ||||
-rw-r--r-- | po/tr.po | 40 | ||||
-rw-r--r-- | po/weechat.pot | 23 | ||||
-rw-r--r-- | src/plugins/trigger/trigger-command.c | 139 |
16 files changed, 854 insertions, 42 deletions
diff --git a/ChangeLog.adoc b/ChangeLog.adoc index 9777a877b..ebe9533ef 100644 --- a/ChangeLog.adoc +++ b/ChangeLog.adoc @@ -18,6 +18,7 @@ New features:: * core: add variables "_chat_focused_line_bol" and "_chat_focused_line_eol" in focus data (issue #1955) * api: add info "buffer" (issue #1962) * irc: display commands 716/717 in private buffer (if present) (issue #146) + * trigger: add options `-o`, `-ol`, `-i` and `-il` in command `/trigger list` (issue #1953) Bug fixes:: @@ -21,7 +21,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2023-07-04 18:42+0200\n" +"POT-Creation-Date: 2023-07-04 21:49+0200\n" "PO-Revision-Date: 2023-06-26 21:34+0200\n" "Last-Translator: Ondřej Súkup <mimi.vx@gmail.com>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -13277,6 +13277,22 @@ msgid "No trigger defined" msgstr "Žádné proxy nejsou definovány" #, fuzzy +msgid "Triggers enabled:" +msgstr "Seznam trigerů:" + +#, fuzzy +#| msgid "default: " +msgid "default" +msgstr "výchozí: " + +msgid "custom" +msgstr "" + +#, fuzzy +msgid "No triggers enabled" +msgstr "Seznam trigerů:" + +#, fuzzy msgid "List of default triggers:" msgstr "Seznam trigerů:" @@ -13419,7 +13435,8 @@ msgid "manage triggers, the Swiss Army knife for WeeChat" msgstr "" msgid "" -"list|listfull|listdefault || add|addoff|addreplace <name> <hook> " +"list [-o|-ol|-i|-il] || listfull || listdefault || add|addoff|addreplace " +"<name> <hook> " "[\"<arguments>\" [\"<conditions>\" [\"<regex>\" [\"<command>\" [\"<return_code>\" [\"<post_action>\"]]]]]] " "|| addinput [<hook>] || input|output|recreate <name> || set <name> <option> " "<value> || rename|copy <name> <new_name> || enable|disable|toggle [<name>|-" @@ -13430,6 +13447,12 @@ msgstr "" msgid "" " list: list triggers (without argument, this list is displayed)\n" +" -o: send list of triggers enabled to buffer (string in English)\n" +" -ol: send list of triggers enabled to buffer (translated string)\n" +" -i: copy list of triggers enabled in command line (for sending to " +"buffer) (string in English)\n" +" -il: copy list of triggers enabled in command line (for sending to " +"buffer) (translated string)\n" " listfull: list triggers with detailed info for each trigger\n" "listdefault: list default triggers\n" " add: add a trigger\n" @@ -26,7 +26,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2023-07-04 18:42+0200\n" +"POT-Creation-Date: 2023-07-04 21:49+0200\n" "PO-Revision-Date: 2023-07-01 12:12+0200\n" "Last-Translator: Nils Görs <weechatter@arcor.de>\n" "Language-Team: German <kde-i18n-de@kde.org>\n" @@ -15950,6 +15950,24 @@ msgstr " %s%s%s: %s%s%s%s%s%s%s%s%s%s%s%s%s" msgid "No trigger defined" msgstr "Kein Trigger definiert" +#, fuzzy +#| msgid "Triggers enabled" +msgid "Triggers enabled:" +msgstr "Trigger aktiviert" + +#, fuzzy +#| msgid "default: " +msgid "default" +msgstr "Standardwert: " + +msgid "custom" +msgstr "" + +#, fuzzy +#| msgid "Triggers enabled" +msgid "No triggers enabled" +msgstr "Trigger aktiviert" + msgid "List of default triggers:" msgstr "Liste der standardmäßigen Trigger:" @@ -16093,8 +16111,18 @@ msgstr "" msgid "manage triggers, the Swiss Army knife for WeeChat" msgstr "verwaltet Trigger, das Schweizer Armeemesser für WeeChat" -msgid "" -"list|listfull|listdefault || add|addoff|addreplace <name> <hook> " +#, fuzzy +#| msgid "" +#| "list|listfull|listdefault || add|addoff|addreplace <name> <hook> " +#| "[\"<arguments>\" [\"<conditions>\" [\"<regex>\" [\"<command>\" [\"<return_code>\" [\"<post_action>\"]]]]]] " +#| "|| addinput [<hook>] || input|output|recreate <name> || set <name> " +#| "<option> <value> || rename|copy <name> <new_name> || enable|disable|" +#| "toggle [<name>|-all [<name>...]] || restart <name>|-all [<name>...] || " +#| "show <name> || del <name>|-all [<name>...] || restore <name> [<name>...] " +#| "|| default -yes || monitor [<filter>]" +msgid "" +"list [-o|-ol|-i|-il] || listfull || listdefault || add|addoff|addreplace " +"<name> <hook> " "[\"<arguments>\" [\"<conditions>\" [\"<regex>\" [\"<command>\" [\"<return_code>\" [\"<post_action>\"]]]]]] " "|| addinput [<hook>] || input|output|recreate <name> || set <name> <option> " "<value> || rename|copy <name> <new_name> || enable|disable|toggle [<name>|-" @@ -16110,8 +16138,113 @@ msgstr "" "<name>|-all [<name>...] || restore <name> [<name>...] || default -yes || " "monitor [<filter>]" +#, fuzzy +#| msgid "" +#| " list: list triggers (without argument, this list is displayed)\n" +#| " listfull: list triggers with detailed info for each trigger\n" +#| "listdefault: list default triggers\n" +#| " add: add a trigger\n" +#| " addoff: add a trigger (disabled)\n" +#| " addreplace: add or replace an existing trigger\n" +#| " name: name of trigger\n" +#| " hook: signal, hsignal, modifier, line, print, command, " +#| "command_run, timer, config, focus, info, info_hashtable\n" +#| " arguments: arguments for the hook, depending on hook (separated by " +#| "semicolons):\n" +#| " signal: name(s) of signal (required)\n" +#| " hsignal: name(s) of hsignal (required)\n" +#| " modifier: name(s) of modifier (required)\n" +#| " line: buffer type (\"formatted\", \"free\" or \"*\"), list " +#| "of buffer masks, tags\n" +#| " print: buffer, tags, message, strip colors\n" +#| " command: command (required), description, arguments, " +#| "description of arguments, completion (all arguments except command are " +#| "evaluated, \"${tg_trigger_name}\" is replaced by the trigger name, see /" +#| "help eval)\n" +#| " command_run: command(s) (required)\n" +#| " timer: interval (required), align on second, max calls\n" +#| " config: name(s) of option (required)\n" +#| " focus: name(s) of area (required)\n" +#| " info: name(s) of info (required)\n" +#| " info_hashtable: name(s) of info (required)\n" +#| " conditions: evaluated conditions for the trigger\n" +#| " regex: one or more regular expressions to replace strings in " +#| "variables\n" +#| " command: command to execute (many commands can be separated by \";" +#| "\")\n" +#| "return_code: return code in callback (ok (default), ok_eat, error)\n" +#| "post_action: action to take after execution (none (default), disable, " +#| "delete)\n" +#| " addinput: set input with default arguments to create a trigger\n" +#| " input: set input with the command used to create the trigger\n" +#| " output: send the command to create the trigger on the buffer\n" +#| " recreate: same as \"input\", with option \"addreplace\" instead of " +#| "\"add\"\n" +#| " set: set an option in a trigger\n" +#| " option: name of option: name, hook, arguments, conditions, regex, " +#| "command, return_code\n" +#| " (for help on option, you can type: /help trigger.trigger." +#| "<name>.<option>)\n" +#| " value: new value for the option\n" +#| " rename: rename a trigger\n" +#| " copy: copy a trigger\n" +#| " enable: enable trigger(s) (without arguments: enable triggers " +#| "globally)\n" +#| " disable: disable trigger(s) (without arguments: disable triggers " +#| "globally)\n" +#| " toggle: toggle trigger(s) (without arguments: toggle triggers " +#| "globally)\n" +#| " restart: restart trigger(s) (recreate the hooks)\n" +#| " show: show detailed info on a trigger (with some stats)\n" +#| " del: delete a trigger\n" +#| " -all: do action on all triggers\n" +#| " restore: restore trigger(s) with the default values (works only for " +#| "default triggers)\n" +#| " default: delete all triggers and restore default ones\n" +#| " monitor: open the trigger monitor buffer, with optional filter:\n" +#| " filter: filter hooks/triggers to display (a hook must start with " +#| "\"@\", for example \"@signal\"), many filters can be separated by commas; " +#| "wildcard \"*\" is allowed in each trigger name\n" +#| "\n" +#| "When a trigger callback is called, following actions are performed, in " +#| "this order:\n" +#| " 1. check conditions; if false, exit\n" +#| " 2. replace text using POSIX extended regular expression(s) (if defined " +#| "in trigger)\n" +#| " 3. execute command(s) (if defined in trigger)\n" +#| " 4. exit with a return code (except for modifier, line, focus, info and " +#| "info_hashtable)\n" +#| " 5. perform post action\n" +#| "\n" +#| "Examples (you can also look at default triggers with /trigger " +#| "listdefault):\n" +#| " add text attributes *bold*, _underline_ and /italic/ (only in user " +#| "messages):\n" +#| " /trigger add effects modifier weechat_print \"${tg_tag_nick}\" " +#| "\"==\\*([^ ]+)\\*==*${color:bold}${re:1}${color:-bold}*== " +#| "==_([^ ]+)_==_${color:underline}${re:1}${color:-underline}_== ==/([^ ]+)/" +#| "==/${color:italic}${re:1}${color:-italic}/\"\n" +#| " hide nicklist bar on small terminals:\n" +#| " /trigger add resize_small signal signal_sigwinch \"${info:term_width} " +#| "< 100\" \"\" \"/bar hide nicklist\"\n" +#| " /trigger add resize_big signal signal_sigwinch \"${info:term_width} " +#| ">= 100\" \"\" \"/bar show nicklist\"\n" +#| " silently save config each hour:\n" +#| " /trigger add cfgsave timer 3600000;0;0 \"\" \"\" \"/mute /save\"\n" +#| " silently save WeeChat session at midnight (see /help upgrade):\n" +#| " /trigger add session_save signal day_changed \"\" \"\" \"/mute /" +#| "upgrade -save\"\n" +#| " open trigger monitor and show only modifiers and triggers whose name " +#| "starts with \"resize\":\n" +#| " /trigger monitor @modifier,resize*" msgid "" " list: list triggers (without argument, this list is displayed)\n" +" -o: send list of triggers enabled to buffer (string in English)\n" +" -ol: send list of triggers enabled to buffer (translated string)\n" +" -i: copy list of triggers enabled in command line (for sending to " +"buffer) (string in English)\n" +" -il: copy list of triggers enabled in command line (for sending to " +"buffer) (translated string)\n" " listfull: list triggers with detailed info for each trigger\n" "listdefault: list default triggers\n" " add: add a trigger\n" @@ -22,7 +22,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2023-07-04 18:42+0200\n" +"POT-Creation-Date: 2023-07-04 21:49+0200\n" "PO-Revision-Date: 2023-06-26 21:34+0200\n" "Last-Translator: Santiago Forero <santiago@forero.xyz>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -13944,6 +13944,22 @@ msgid "No trigger defined" msgstr "Ningún modificador regular definido" #, fuzzy +msgid "Triggers enabled:" +msgstr "Filtro \"%s\" activado" + +#, fuzzy +#| msgid "default: " +msgid "default" +msgstr "predeterminado: " + +msgid "custom" +msgstr "" + +#, fuzzy +msgid "No triggers enabled" +msgstr "Filtro \"%s\" activado" + +#, fuzzy msgid "List of default triggers:" msgstr "Lista de alias:" @@ -14087,7 +14103,8 @@ msgid "manage triggers, the Swiss Army knife for WeeChat" msgstr "" msgid "" -"list|listfull|listdefault || add|addoff|addreplace <name> <hook> " +"list [-o|-ol|-i|-il] || listfull || listdefault || add|addoff|addreplace " +"<name> <hook> " "[\"<arguments>\" [\"<conditions>\" [\"<regex>\" [\"<command>\" [\"<return_code>\" [\"<post_action>\"]]]]]] " "|| addinput [<hook>] || input|output|recreate <name> || set <name> <option> " "<value> || rename|copy <name> <new_name> || enable|disable|toggle [<name>|-" @@ -14098,6 +14115,12 @@ msgstr "" msgid "" " list: list triggers (without argument, this list is displayed)\n" +" -o: send list of triggers enabled to buffer (string in English)\n" +" -ol: send list of triggers enabled to buffer (translated string)\n" +" -i: copy list of triggers enabled in command line (for sending to " +"buffer) (string in English)\n" +" -il: copy list of triggers enabled in command line (for sending to " +"buffer) (translated string)\n" " listfull: list triggers with detailed info for each trigger\n" "listdefault: list default triggers\n" " add: add a trigger\n" @@ -21,8 +21,8 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2023-07-04 18:42+0200\n" -"PO-Revision-Date: 2023-07-04 18:45+0200\n" +"POT-Creation-Date: 2023-07-04 21:49+0200\n" +"PO-Revision-Date: 2023-07-04 21:53+0200\n" "Last-Translator: Sébastien Helleu <flashcode@flashtux.org>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" "Language: fr\n" @@ -15578,6 +15578,18 @@ msgstr " %s%s%s : %s%s%s%s%s%s%s%s%s%s%s%s%s" msgid "No trigger defined" msgstr "Pas de trigger défini" +msgid "Triggers enabled:" +msgstr "Triggers activés :" + +msgid "default" +msgstr "par défaut" + +msgid "custom" +msgstr "personnalisé" + +msgid "No triggers enabled" +msgstr "Aucun trigger activé" + msgid "List of default triggers:" msgstr "Liste des triggers par défaut :" @@ -15723,7 +15735,8 @@ msgid "manage triggers, the Swiss Army knife for WeeChat" msgstr "gestion des triggers, le couteau Suisse pour WeeChat" msgid "" -"list|listfull|listdefault || add|addoff|addreplace <name> <hook> " +"list [-o|-ol|-i|-il] || listfull || listdefault || add|addoff|addreplace " +"<name> <hook> " "[\"<arguments>\" [\"<conditions>\" [\"<regex>\" [\"<command>\" [\"<return_code>\" [\"<post_action>\"]]]]]] " "|| addinput [<hook>] || input|output|recreate <name> || set <name> <option> " "<value> || rename|copy <name> <new_name> || enable|disable|toggle [<name>|-" @@ -15731,7 +15744,8 @@ msgid "" "<name>|-all [<name>...] || restore <name> [<name>...] || default -yes || " "monitor [<filter>]" msgstr "" -"list|listfull|listdefault || add|addoff|addreplace <nom> <hook> " +"list [-o|-ol|-i|-il] || listfull || listdefault || add|addoff|addreplace " +"<nom> <hook> " "[\"<paramètres>\" [\"<conditions>\" [\"<regex>\" [\"<commande>\" [\"<code_retour>\" [\"action_post\"]]]]]] " "|| addinput [<hook>] || input|output|recreate <nom> || set <nom> <option> " "<valeur> || rename|copy <nom> <nouveau_nom> || enable|disable|toggle [<nom>|-" @@ -15741,6 +15755,12 @@ msgstr "" msgid "" " list: list triggers (without argument, this list is displayed)\n" +" -o: send list of triggers enabled to buffer (string in English)\n" +" -ol: send list of triggers enabled to buffer (translated string)\n" +" -i: copy list of triggers enabled in command line (for sending to " +"buffer) (string in English)\n" +" -il: copy list of triggers enabled in command line (for sending to " +"buffer) (translated string)\n" " listfull: list triggers with detailed info for each trigger\n" "listdefault: list default triggers\n" " add: add a trigger\n" @@ -15838,6 +15858,14 @@ msgid "" msgstr "" " list : lister les triggers (sans paramètre, cette liste est " "affichée)\n" +" -o : envoyer la liste des triggers activés au tampon (chaîne en " +"anglais)\n" +" -ol : envoyer la liste des triggers activés au tampon (chaîne " +"traduite)\n" +" -i : copier la liste des triggers activés dans la ligne de commande " +"(pour envoi au tampon) (chaîne en anglais)\n" +" -il : copier la liste des triggers activés dans la ligne de commande " +"(pour envoi au tampon) (chaîne traduite)\n" " listfull : lister les triggers avec des informations détaillées pour " "chaque trigger\n" "listdefault : lister les triggers par défaut\n" @@ -20,7 +20,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2023-07-04 18:42+0200\n" +"POT-Creation-Date: 2023-07-04 21:49+0200\n" "PO-Revision-Date: 2023-06-17 11:47+0200\n" "Last-Translator: Andras Voroskoi <voroskoi@frugalware.org>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -12539,6 +12539,21 @@ msgid "No trigger defined" msgstr "Nincs aliasz definiálva.\n" #, fuzzy +msgid "Triggers enabled:" +msgstr "a felhasználók le lettek tiltva" + +#, fuzzy +msgid "default" +msgstr " . alapérték: %d\n" + +msgid "custom" +msgstr "" + +#, fuzzy +msgid "No triggers enabled" +msgstr "a felhasználók le lettek tiltva" + +#, fuzzy msgid "List of default triggers:" msgstr "Aliaszok listája:\n" @@ -12681,7 +12696,8 @@ msgid "manage triggers, the Swiss Army knife for WeeChat" msgstr "" msgid "" -"list|listfull|listdefault || add|addoff|addreplace <name> <hook> " +"list [-o|-ol|-i|-il] || listfull || listdefault || add|addoff|addreplace " +"<name> <hook> " "[\"<arguments>\" [\"<conditions>\" [\"<regex>\" [\"<command>\" [\"<return_code>\" [\"<post_action>\"]]]]]] " "|| addinput [<hook>] || input|output|recreate <name> || set <name> <option> " "<value> || rename|copy <name> <new_name> || enable|disable|toggle [<name>|-" @@ -12692,6 +12708,12 @@ msgstr "" msgid "" " list: list triggers (without argument, this list is displayed)\n" +" -o: send list of triggers enabled to buffer (string in English)\n" +" -ol: send list of triggers enabled to buffer (translated string)\n" +" -i: copy list of triggers enabled in command line (for sending to " +"buffer) (string in English)\n" +" -il: copy list of triggers enabled in command line (for sending to " +"buffer) (translated string)\n" " listfull: list triggers with detailed info for each trigger\n" "listdefault: list default triggers\n" " add: add a trigger\n" @@ -20,7 +20,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2023-07-04 18:42+0200\n" +"POT-Creation-Date: 2023-07-04 21:49+0200\n" "PO-Revision-Date: 2023-06-26 21:34+0200\n" "Last-Translator: Esteban I. Ruiz Moreno <exio4.com@gmail.com>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -13720,6 +13720,22 @@ msgid "No trigger defined" msgstr "Nessun rmodifier definito" #, fuzzy +msgid "Triggers enabled:" +msgstr "Filtro \"%s\" abilitato" + +#, fuzzy +#| msgid "default: " +msgid "default" +msgstr "predefinito: " + +msgid "custom" +msgstr "" + +#, fuzzy +msgid "No triggers enabled" +msgstr "Filtro \"%s\" abilitato" + +#, fuzzy msgid "List of default triggers:" msgstr "Elenco degli alias:" @@ -13863,7 +13879,8 @@ msgid "manage triggers, the Swiss Army knife for WeeChat" msgstr "" msgid "" -"list|listfull|listdefault || add|addoff|addreplace <name> <hook> " +"list [-o|-ol|-i|-il] || listfull || listdefault || add|addoff|addreplace " +"<name> <hook> " "[\"<arguments>\" [\"<conditions>\" [\"<regex>\" [\"<command>\" [\"<return_code>\" [\"<post_action>\"]]]]]] " "|| addinput [<hook>] || input|output|recreate <name> || set <name> <option> " "<value> || rename|copy <name> <new_name> || enable|disable|toggle [<name>|-" @@ -13874,6 +13891,12 @@ msgstr "" msgid "" " list: list triggers (without argument, this list is displayed)\n" +" -o: send list of triggers enabled to buffer (string in English)\n" +" -ol: send list of triggers enabled to buffer (translated string)\n" +" -i: copy list of triggers enabled in command line (for sending to " +"buffer) (string in English)\n" +" -il: copy list of triggers enabled in command line (for sending to " +"buffer) (translated string)\n" " listfull: list triggers with detailed info for each trigger\n" "listdefault: list default triggers\n" " add: add a trigger\n" @@ -20,7 +20,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2023-07-04 18:42+0200\n" +"POT-Creation-Date: 2023-07-04 21:49+0200\n" "PO-Revision-Date: 2023-06-26 21:34+0200\n" "Last-Translator: AYANOKOUZI, Ryuunosuke <i38w7i3@yahoo.co.jp>\n" "Language-Team: Japanese <https://github.com/l/weechat/tree/master/" @@ -15074,6 +15074,24 @@ msgstr "%s%s%s: %s %s[%s%s]%s" msgid "No trigger defined" msgstr "トリガは定義されていません" +#, fuzzy +#| msgid "Triggers enabled" +msgid "Triggers enabled:" +msgstr "トリガが有効化されました" + +#, fuzzy +#| msgid "default: " +msgid "default" +msgstr "デフォルト: " + +msgid "custom" +msgstr "" + +#, fuzzy +#| msgid "Triggers enabled" +msgid "No triggers enabled" +msgstr "トリガが有効化されました" + msgid "List of default triggers:" msgstr "デフォルトトリガのリスト:" @@ -15220,8 +15238,18 @@ msgstr "" msgid "manage triggers, the Swiss Army knife for WeeChat" msgstr "トリガ (WeeChat 用のスイスアーミーナイフ) の管理" -msgid "" -"list|listfull|listdefault || add|addoff|addreplace <name> <hook> " +#, fuzzy +#| msgid "" +#| "list|listfull|listdefault || add|addoff|addreplace <name> <hook> " +#| "[\"<arguments>\" [\"<conditions>\" [\"<regex>\" [\"<command>\" [\"<return_code>\" [\"<post_action>\"]]]]]] " +#| "|| addinput [<hook>] || input|output|recreate <name> || set <name> " +#| "<option> <value> || rename|copy <name> <new_name> || enable|disable|" +#| "toggle [<name>|-all [<name>...]] || restart <name>|-all [<name>...] || " +#| "show <name> || del <name>|-all [<name>...] || restore <name> [<name>...] " +#| "|| default -yes || monitor [<filter>]" +msgid "" +"list [-o|-ol|-i|-il] || listfull || listdefault || add|addoff|addreplace " +"<name> <hook> " "[\"<arguments>\" [\"<conditions>\" [\"<regex>\" [\"<command>\" [\"<return_code>\" [\"<post_action>\"]]]]]] " "|| addinput [<hook>] || input|output|recreate <name> || set <name> <option> " "<value> || rename|copy <name> <new_name> || enable|disable|toggle [<name>|-" @@ -15240,6 +15268,12 @@ msgstr "" #, fuzzy msgid "" " list: list triggers (without argument, this list is displayed)\n" +" -o: send list of triggers enabled to buffer (string in English)\n" +" -ol: send list of triggers enabled to buffer (translated string)\n" +" -i: copy list of triggers enabled in command line (for sending to " +"buffer) (string in English)\n" +" -il: copy list of triggers enabled in command line (for sending to " +"buffer) (translated string)\n" " listfull: list triggers with detailed info for each trigger\n" "listdefault: list default triggers\n" " add: add a trigger\n" @@ -22,7 +22,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2023-07-04 18:42+0200\n" +"POT-Creation-Date: 2023-07-04 21:49+0200\n" "PO-Revision-Date: 2023-06-26 21:34+0200\n" "Last-Translator: Krzysztof Korościk <soltys@soltys.info>\n" "Language-Team: Polish <kde-i18n-doc@kde.org>\n" @@ -16208,6 +16208,24 @@ msgstr "%s%s%s: %s %s[%s%s]%s" msgid "No trigger defined" msgstr "Nie zdefiniowano triggerów" +#, fuzzy +#| msgid "Triggers enabled" +msgid "Triggers enabled:" +msgstr "Triggery włączone" + +#, fuzzy +#| msgid "default: " +msgid "default" +msgstr "domyślnie: " + +msgid "custom" +msgstr "" + +#, fuzzy +#| msgid "Triggers enabled" +msgid "No triggers enabled" +msgstr "Triggery włączone" + msgid "List of default triggers:" msgstr "Lista domyślnych triggerów:" @@ -16351,8 +16369,18 @@ msgstr "" msgid "manage triggers, the Swiss Army knife for WeeChat" msgstr "zarządzaj triggerami, scyzorykiem WeeChat" -msgid "" -"list|listfull|listdefault || add|addoff|addreplace <name> <hook> " +#, fuzzy +#| msgid "" +#| "list|listfull|listdefault || add|addoff|addreplace <name> <hook> " +#| "[\"<arguments>\" [\"<conditions>\" [\"<regex>\" [\"<command>\" [\"<return_code>\" [\"<post_action>\"]]]]]] " +#| "|| addinput [<hook>] || input|output|recreate <name> || set <name> " +#| "<option> <value> || rename|copy <name> <new_name> || enable|disable|" +#| "toggle [<name>|-all [<name>...]] || restart <name>|-all [<name>...] || " +#| "show <name> || del <name>|-all [<name>...] || restore <name> [<name>...] " +#| "|| default -yes || monitor [<filter>]" +msgid "" +"list [-o|-ol|-i|-il] || listfull || listdefault || add|addoff|addreplace " +"<name> <hook> " "[\"<arguments>\" [\"<conditions>\" [\"<regex>\" [\"<command>\" [\"<return_code>\" [\"<post_action>\"]]]]]] " "|| addinput [<hook>] || input|output|recreate <name> || set <name> <option> " "<value> || rename|copy <name> <new_name> || enable|disable|toggle [<name>|-" @@ -16368,8 +16396,113 @@ msgstr "" "<nazwa> || del <nazwa>|-all [<nazwa>...] || restore <nazwa> [<nazwa>...] || " "default -yes || monitor [<filtr>]" +#, fuzzy +#| msgid "" +#| " list: list triggers (without argument, this list is displayed)\n" +#| " listfull: list triggers with detailed info for each trigger\n" +#| "listdefault: list default triggers\n" +#| " add: add a trigger\n" +#| " addoff: add a trigger (disabled)\n" +#| " addreplace: add or replace an existing trigger\n" +#| " name: name of trigger\n" +#| " hook: signal, hsignal, modifier, line, print, command, " +#| "command_run, timer, config, focus, info, info_hashtable\n" +#| " arguments: arguments for the hook, depending on hook (separated by " +#| "semicolons):\n" +#| " signal: name(s) of signal (required)\n" +#| " hsignal: name(s) of hsignal (required)\n" +#| " modifier: name(s) of modifier (required)\n" +#| " line: buffer type (\"formatted\", \"free\" or \"*\"), list " +#| "of buffer masks, tags\n" +#| " print: buffer, tags, message, strip colors\n" +#| " command: command (required), description, arguments, " +#| "description of arguments, completion (all arguments except command are " +#| "evaluated, \"${tg_trigger_name}\" is replaced by the trigger name, see /" +#| "help eval)\n" +#| " command_run: command(s) (required)\n" +#| " timer: interval (required), align on second, max calls\n" +#| " config: name(s) of option (required)\n" +#| " focus: name(s) of area (required)\n" +#| " info: name(s) of info (required)\n" +#| " info_hashtable: name(s) of info (required)\n" +#| " conditions: evaluated conditions for the trigger\n" +#| " regex: one or more regular expressions to replace strings in " +#| "variables\n" +#| " command: command to execute (many commands can be separated by \";" +#| "\")\n" +#| "return_code: return code in callback (ok (default), ok_eat, error)\n" +#| "post_action: action to take after execution (none (default), disable, " +#| "delete)\n" +#| " addinput: set input with default arguments to create a trigger\n" +#| " input: set input with the command used to create the trigger\n" +#| " output: send the command to create the trigger on the buffer\n" +#| " recreate: same as \"input\", with option \"addreplace\" instead of " +#| "\"add\"\n" +#| " set: set an option in a trigger\n" +#| " option: name of option: name, hook, arguments, conditions, regex, " +#| "command, return_code\n" +#| " (for help on option, you can type: /help trigger.trigger." +#| "<name>.<option>)\n" +#| " value: new value for the option\n" +#| " rename: rename a trigger\n" +#| " copy: copy a trigger\n" +#| " enable: enable trigger(s) (without arguments: enable triggers " +#| "globally)\n" +#| " disable: disable trigger(s) (without arguments: disable triggers " +#| "globally)\n" +#| " toggle: toggle trigger(s) (without arguments: toggle triggers " +#| "globally)\n" +#| " restart: restart trigger(s) (recreate the hooks)\n" +#| " show: show detailed info on a trigger (with some stats)\n" +#| " del: delete a trigger\n" +#| " -all: do action on all triggers\n" +#| " restore: restore trigger(s) with the default values (works only for " +#| "default triggers)\n" +#| " default: delete all triggers and restore default ones\n" +#| " monitor: open the trigger monitor buffer, with optional filter:\n" +#| " filter: filter hooks/triggers to display (a hook must start with " +#| "\"@\", for example \"@signal\"), many filters can be separated by commas; " +#| "wildcard \"*\" is allowed in each trigger name\n" +#| "\n" +#| "When a trigger callback is called, following actions are performed, in " +#| "this order:\n" +#| " 1. check conditions; if false, exit\n" +#| " 2. replace text using POSIX extended regular expression(s) (if defined " +#| "in trigger)\n" +#| " 3. execute command(s) (if defined in trigger)\n" +#| " 4. exit with a return code (except for modifier, line, focus, info and " +#| "info_hashtable)\n" +#| " 5. perform post action\n" +#| "\n" +#| "Examples (you can also look at default triggers with /trigger " +#| "listdefault):\n" +#| " add text attributes *bold*, _underline_ and /italic/ (only in user " +#| "messages):\n" +#| " /trigger add effects modifier weechat_print \"${tg_tag_nick}\" " +#| "\"==\\*([^ ]+)\\*==*${color:bold}${re:1}${color:-bold}*== " +#| "==_([^ ]+)_==_${color:underline}${re:1}${color:-underline}_== ==/([^ ]+)/" +#| "==/${color:italic}${re:1}${color:-italic}/\"\n" +#| " hide nicklist bar on small terminals:\n" +#| " /trigger add resize_small signal signal_sigwinch \"${info:term_width} " +#| "< 100\" \"\" \"/bar hide nicklist\"\n" +#| " /trigger add resize_big signal signal_sigwinch \"${info:term_width} " +#| ">= 100\" \"\" \"/bar show nicklist\"\n" +#| " silently save config each hour:\n" +#| " /trigger add cfgsave timer 3600000;0;0 \"\" \"\" \"/mute /save\"\n" +#| " silently save WeeChat session at midnight (see /help upgrade):\n" +#| " /trigger add session_save signal day_changed \"\" \"\" \"/mute /" +#| "upgrade -save\"\n" +#| " open trigger monitor and show only modifiers and triggers whose name " +#| "starts with \"resize\":\n" +#| " /trigger monitor @modifier,resize*" msgid "" " list: list triggers (without argument, this list is displayed)\n" +" -o: send list of triggers enabled to buffer (string in English)\n" +" -ol: send list of triggers enabled to buffer (translated string)\n" +" -i: copy list of triggers enabled in command line (for sending to " +"buffer) (string in English)\n" +" -il: copy list of triggers enabled in command line (for sending to " +"buffer) (translated string)\n" " listfull: list triggers with detailed info for each trigger\n" "listdefault: list default triggers\n" " add: add a trigger\n" @@ -20,7 +20,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2023-07-04 18:42+0200\n" +"POT-Creation-Date: 2023-07-04 21:49+0200\n" "PO-Revision-Date: 2023-06-26 21:34+0200\n" "Last-Translator: Vasco Almeida <vascomalmeida@sapo.pt>\n" "Language-Team: Portuguese <>\n" @@ -14824,6 +14824,24 @@ msgstr "%sNicks %s%s%s: %s[%s%s%s]" msgid "No trigger defined" msgstr "Nenhum acionador definido" +#, fuzzy +#| msgid "Triggers enabled" +msgid "Triggers enabled:" +msgstr "Acionadores ativado" + +#, fuzzy +#| msgid "default: " +msgid "default" +msgstr "predefinição: " + +msgid "custom" +msgstr "" + +#, fuzzy +#| msgid "Triggers enabled" +msgid "No triggers enabled" +msgstr "Acionadores ativado" + msgid "List of default triggers:" msgstr "Lista de acionadores predefinidos:" @@ -14970,8 +14988,18 @@ msgstr "" msgid "manage triggers, the Swiss Army knife for WeeChat" msgstr "gerir acionadores, o canivete suíço do WeeChat" -msgid "" -"list|listfull|listdefault || add|addoff|addreplace <name> <hook> " +#, fuzzy +#| msgid "" +#| "list|listfull|listdefault || add|addoff|addreplace <name> <hook> " +#| "[\"<arguments>\" [\"<conditions>\" [\"<regex>\" [\"<command>\" [\"<return_code>\" [\"<post_action>\"]]]]]] " +#| "|| addinput [<hook>] || input|output|recreate <name> || set <name> " +#| "<option> <value> || rename|copy <name> <new_name> || enable|disable|" +#| "toggle [<name>|-all [<name>...]] || restart <name>|-all [<name>...] || " +#| "show <name> || del <name>|-all [<name>...] || restore <name> [<name>...] " +#| "|| default -yes || monitor [<filter>]" +msgid "" +"list [-o|-ol|-i|-il] || listfull || listdefault || add|addoff|addreplace " +"<name> <hook> " "[\"<arguments>\" [\"<conditions>\" [\"<regex>\" [\"<command>\" [\"<return_code>\" [\"<post_action>\"]]]]]] " "|| addinput [<hook>] || input|output|recreate <name> || set <name> <option> " "<value> || rename|copy <name> <new_name> || enable|disable|toggle [<name>|-" @@ -14990,6 +15018,12 @@ msgstr "" #, fuzzy msgid "" " list: list triggers (without argument, this list is displayed)\n" +" -o: send list of triggers enabled to buffer (string in English)\n" +" -ol: send list of triggers enabled to buffer (translated string)\n" +" -i: copy list of triggers enabled in command line (for sending to " +"buffer) (string in English)\n" +" -il: copy list of triggers enabled in command line (for sending to " +"buffer) (translated string)\n" " listfull: list triggers with detailed info for each trigger\n" "listdefault: list default triggers\n" " add: add a trigger\n" diff --git a/po/pt_BR.po b/po/pt_BR.po index 8266721de..3dca51dff 100644 --- a/po/pt_BR.po +++ b/po/pt_BR.po @@ -21,7 +21,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2023-07-04 18:42+0200\n" +"POT-Creation-Date: 2023-07-04 21:49+0200\n" "PO-Revision-Date: 2023-06-26 21:34+0200\n" "Last-Translator: Érico Nogueira <ericonr@disroot.org>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -13146,6 +13146,22 @@ msgid "No trigger defined" msgstr "Nenhuma rmodifier definido" #, fuzzy +msgid "Triggers enabled:" +msgstr "Filtro \"%s\" habilitado" + +#, fuzzy +#| msgid "default: " +msgid "default" +msgstr "padrão: " + +msgid "custom" +msgstr "" + +#, fuzzy +msgid "No triggers enabled" +msgstr "Filtro \"%s\" habilitado" + +#, fuzzy msgid "List of default triggers:" msgstr "Lista de atalhos:" @@ -13289,7 +13305,8 @@ msgid "manage triggers, the Swiss Army knife for WeeChat" msgstr "" msgid "" -"list|listfull|listdefault || add|addoff|addreplace <name> <hook> " +"list [-o|-ol|-i|-il] || listfull || listdefault || add|addoff|addreplace " +"<name> <hook> " "[\"<arguments>\" [\"<conditions>\" [\"<regex>\" [\"<command>\" [\"<return_code>\" [\"<post_action>\"]]]]]] " "|| addinput [<hook>] || input|output|recreate <name> || set <name> <option> " "<value> || rename|copy <name> <new_name> || enable|disable|toggle [<name>|-" @@ -13300,6 +13317,12 @@ msgstr "" msgid "" " list: list triggers (without argument, this list is displayed)\n" +" -o: send list of triggers enabled to buffer (string in English)\n" +" -ol: send list of triggers enabled to buffer (translated string)\n" +" -i: copy list of triggers enabled in command line (for sending to " +"buffer) (string in English)\n" +" -il: copy list of triggers enabled in command line (for sending to " +"buffer) (translated string)\n" " listfull: list triggers with detailed info for each trigger\n" "listdefault: list default triggers\n" " add: add a trigger\n" @@ -21,7 +21,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2023-07-04 18:42+0200\n" +"POT-Creation-Date: 2023-07-04 21:49+0200\n" "PO-Revision-Date: 2023-06-17 11:47+0200\n" "Last-Translator: Aleksey V Zapparov AKA ixti <ixti@member.fsf.org>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -12577,6 +12577,21 @@ msgid "No trigger defined" msgstr "Сокращения не заданы.\n" #, fuzzy +msgid "Triggers enabled:" +msgstr "команда users отключена" + +#, fuzzy +msgid "default" +msgstr " . значение по умолчанию: %d\n" + +msgid "custom" +msgstr "" + +#, fuzzy +msgid "No triggers enabled" +msgstr "команда users отключена" + +#, fuzzy msgid "List of default triggers:" msgstr "Список сокращений:\n" @@ -12718,7 +12733,8 @@ msgid "manage triggers, the Swiss Army knife for WeeChat" msgstr "" msgid "" -"list|listfull|listdefault || add|addoff|addreplace <name> <hook> " +"list [-o|-ol|-i|-il] || listfull || listdefault || add|addoff|addreplace " +"<name> <hook> " "[\"<arguments>\" [\"<conditions>\" [\"<regex>\" [\"<command>\" [\"<return_code>\" [\"<post_action>\"]]]]]] " "|| addinput [<hook>] || input|output|recreate <name> || set <name> <option> " "<value> || rename|copy <name> <new_name> || enable|disable|toggle [<name>|-" @@ -12729,6 +12745,12 @@ msgstr "" msgid "" " list: list triggers (without argument, this list is displayed)\n" +" -o: send list of triggers enabled to buffer (string in English)\n" +" -ol: send list of triggers enabled to buffer (translated string)\n" +" -i: copy list of triggers enabled in command line (for sending to " +"buffer) (string in English)\n" +" -il: copy list of triggers enabled in command line (for sending to " +"buffer) (translated string)\n" " listfull: list triggers with detailed info for each trigger\n" "listdefault: list default triggers\n" " add: add a trigger\n" @@ -20,7 +20,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2023-07-04 18:42+0200\n" +"POT-Creation-Date: 2023-07-04 21:49+0200\n" "PO-Revision-Date: 2023-06-26 21:34+0200\n" "Last-Translator: Ivan Pešić <ivan.pesic@gmail.com>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -15278,6 +15278,24 @@ msgstr " %s%s%s: %s%s%s%s%s%s%s%s%s%s%s%s%s" msgid "No trigger defined" msgstr "Није дефинисан ниједан окидач" +#, fuzzy +#| msgid "Triggers enabled" +msgid "Triggers enabled:" +msgstr "Окидачи су укључени" + +#, fuzzy +#| msgid "default: " +msgid "default" +msgstr "подразумевано: " + +msgid "custom" +msgstr "" + +#, fuzzy +#| msgid "Triggers enabled" +msgid "No triggers enabled" +msgstr "Окидачи су укључени" + msgid "List of default triggers:" msgstr "Листа подразумеваних окидача:" @@ -15421,8 +15439,18 @@ msgstr "" msgid "manage triggers, the Swiss Army knife for WeeChat" msgstr "управљање окидачима, ножем швајцарске војске програма WeeChat" -msgid "" -"list|listfull|listdefault || add|addoff|addreplace <name> <hook> " +#, fuzzy +#| msgid "" +#| "list|listfull|listdefault || add|addoff|addreplace <name> <hook> " +#| "[\"<arguments>\" [\"<conditions>\" [\"<regex>\" [\"<command>\" [\"<return_code>\" [\"<post_action>\"]]]]]] " +#| "|| addinput [<hook>] || input|output|recreate <name> || set <name> " +#| "<option> <value> || rename|copy <name> <new_name> || enable|disable|" +#| "toggle [<name>|-all [<name>...]] || restart <name>|-all [<name>...] || " +#| "show <name> || del <name>|-all [<name>...] || restore <name> [<name>...] " +#| "|| default -yes || monitor [<filter>]" +msgid "" +"list [-o|-ol|-i|-il] || listfull || listdefault || add|addoff|addreplace " +"<name> <hook> " "[\"<arguments>\" [\"<conditions>\" [\"<regex>\" [\"<command>\" [\"<return_code>\" [\"<post_action>\"]]]]]] " "|| addinput [<hook>] || input|output|recreate <name> || set <name> <option> " "<value> || rename|copy <name> <new_name> || enable|disable|toggle [<name>|-" @@ -15438,8 +15466,113 @@ msgstr "" "all [<име>...] || restore <име> [<име>...] || default -yes || monitor " "[<филтер>]" +#, fuzzy +#| msgid "" +#| " list: list triggers (without argument, this list is displayed)\n" +#| " listfull: list triggers with detailed info for each trigger\n" +#| "listdefault: list default triggers\n" +#| " add: add a trigger\n" +#| " addoff: add a trigger (disabled)\n" +#| " addreplace: add or replace an existing trigger\n" +#| " name: name of trigger\n" +#| " hook: signal, hsignal, modifier, line, print, command, " +#| "command_run, timer, config, focus, info, info_hashtable\n" +#| " arguments: arguments for the hook, depending on hook (separated by " +#| "semicolons):\n" +#| " signal: name(s) of signal (required)\n" +#| " hsignal: name(s) of hsignal (required)\n" +#| " modifier: name(s) of modifier (required)\n" +#| " line: buffer type (\"formatted\", \"free\" or \"*\"), list " +#| "of buffer masks, tags\n" +#| " print: buffer, tags, message, strip colors\n" +#| " command: command (required), description, arguments, " +#| "description of arguments, completion (all arguments except command are " +#| "evaluated, \"${tg_trigger_name}\" is replaced by the trigger name, see /" +#| "help eval)\n" +#| " command_run: command(s) (required)\n" +#| " timer: interval (required), align on second, max calls\n" +#| " config: name(s) of option (required)\n" +#| " focus: name(s) of area (required)\n" +#| " info: name(s) of info (required)\n" +#| " info_hashtable: name(s) of info (required)\n" +#| " conditions: evaluated conditions for the trigger\n" +#| " regex: one or more regular expressions to replace strings in " +#| "variables\n" +#| " command: command to execute (many commands can be separated by \";" +#| "\")\n" +#| "return_code: return code in callback (ok (default), ok_eat, error)\n" +#| "post_action: action to take after execution (none (default), disable, " +#| "delete)\n" +#| " addinput: set input with default arguments to create a trigger\n" +#| " input: set input with the command used to create the trigger\n" +#| " output: send the command to create the trigger on the buffer\n" +#| " recreate: same as \"input\", with option \"addreplace\" instead of " +#| "\"add\"\n" +#| " set: set an option in a trigger\n" +#| " option: name of option: name, hook, arguments, conditions, regex, " +#| "command, return_code\n" +#| " (for help on option, you can type: /help trigger.trigger." +#| "<name>.<option>)\n" +#| " value: new value for the option\n" +#| " rename: rename a trigger\n" +#| " copy: copy a trigger\n" +#| " enable: enable trigger(s) (without arguments: enable triggers " +#| "globally)\n" +#| " disable: disable trigger(s) (without arguments: disable triggers " +#| "globally)\n" +#| " toggle: toggle trigger(s) (without arguments: toggle triggers " +#| "globally)\n" +#| " restart: restart trigger(s) (recreate the hooks)\n" +#| " show: show detailed info on a trigger (with some stats)\n" +#| " del: delete a trigger\n" +#| " -all: do action on all triggers\n" +#| " restore: restore trigger(s) with the default values (works only for " +#| "default triggers)\n" +#| " default: delete all triggers and restore default ones\n" +#| " monitor: open the trigger monitor buffer, with optional filter:\n" +#| " filter: filter hooks/triggers to display (a hook must start with " +#| "\"@\", for example \"@signal\"), many filters can be separated by commas; " +#| "wildcard \"*\" is allowed in each trigger name\n" +#| "\n" +#| "When a trigger callback is called, following actions are performed, in " +#| "this order:\n" +#| " 1. check conditions; if false, exit\n" +#| " 2. replace text using POSIX extended regular expression(s) (if defined " +#| "in trigger)\n" +#| " 3. execute command(s) (if defined in trigger)\n" +#| " 4. exit with a return code (except for modifier, line, focus, info and " +#| "info_hashtable)\n" +#| " 5. perform post action\n" +#| "\n" +#| "Examples (you can also look at default triggers with /trigger " +#| "listdefault):\n" +#| " add text attributes *bold*, _underline_ and /italic/ (only in user " +#| "messages):\n" +#| " /trigger add effects modifier weechat_print \"${tg_tag_nick}\" " +#| "\"==\\*([^ ]+)\\*==*${color:bold}${re:1}${color:-bold}*== " +#| "==_([^ ]+)_==_${color:underline}${re:1}${color:-underline}_== ==/([^ ]+)/" +#| "==/${color:italic}${re:1}${color:-italic}/\"\n" +#| " hide nicklist bar on small terminals:\n" +#| " /trigger add resize_small signal signal_sigwinch \"${info:term_width} " +#| "< 100\" \"\" \"/bar hide nicklist\"\n" +#| " /trigger add resize_big signal signal_sigwinch \"${info:term_width} " +#| ">= 100\" \"\" \"/bar show nicklist\"\n" +#| " silently save config each hour:\n" +#| " /trigger add cfgsave timer 3600000;0;0 \"\" \"\" \"/mute /save\"\n" +#| " silently save WeeChat session at midnight (see /help upgrade):\n" +#| " /trigger add session_save signal day_changed \"\" \"\" \"/mute /" +#| "upgrade -save\"\n" +#| " open trigger monitor and show only modifiers and triggers whose name " +#| "starts with \"resize\":\n" +#| " /trigger monitor @modifier,resize*" msgid "" " list: list triggers (without argument, this list is displayed)\n" +" -o: send list of triggers enabled to buffer (string in English)\n" +" -ol: send list of triggers enabled to buffer (translated string)\n" +" -i: copy list of triggers enabled in command line (for sending to " +"buffer) (string in English)\n" +" -il: copy list of triggers enabled in command line (for sending to " +"buffer) (translated string)\n" " listfull: list triggers with detailed info for each trigger\n" "listdefault: list default triggers\n" " add: add a trigger\n" @@ -20,7 +20,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2023-07-04 18:42+0200\n" +"POT-Creation-Date: 2023-07-04 21:49+0200\n" "PO-Revision-Date: 2023-06-26 21:34+0200\n" "Last-Translator: Emir SARI <emir_sari@icloud.com>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -15707,6 +15707,24 @@ msgstr "%s%s%s: %s %s[%s%s]%s" msgid "No trigger defined" msgstr "Tanımlanan bir tetik yok" +#, fuzzy +#| msgid "Triggers enabled" +msgid "Triggers enabled:" +msgstr "Tetikler etkin" + +#, fuzzy +#| msgid "default: " +msgid "default" +msgstr "öntanımlı: " + +msgid "custom" +msgstr "" + +#, fuzzy +#| msgid "Triggers enabled" +msgid "No triggers enabled" +msgstr "Tetikler etkin" + msgid "List of default triggers:" msgstr "Öntanımlı tetiklerin listesi:" @@ -15850,8 +15868,18 @@ msgstr "" msgid "manage triggers, the Swiss Army knife for WeeChat" msgstr "WeeChat'in İsviçre Çakısı olan tetikleri yönetin" -msgid "" -"list|listfull|listdefault || add|addoff|addreplace <name> <hook> " +#, fuzzy +#| msgid "" +#| "list|listfull|listdefault || add|addoff|addreplace <name> <hook> " +#| "[\"<arguments>\" [\"<conditions>\" [\"<regex>\" [\"<command>\" [\"<return_code>\" [\"<post_action>\"]]]]]] " +#| "|| addinput [<hook>] || input|output|recreate <name> || set <name> " +#| "<option> <value> || rename|copy <name> <new_name> || enable|disable|" +#| "toggle [<name>|-all [<name>...]] || restart <name>|-all [<name>...] || " +#| "show <name> || del <name>|-all [<name>...] || restore <name> [<name>...] " +#| "|| default -yes || monitor [<filter>]" +msgid "" +"list [-o|-ol|-i|-il] || listfull || listdefault || add|addoff|addreplace " +"<name> <hook> " "[\"<arguments>\" [\"<conditions>\" [\"<regex>\" [\"<command>\" [\"<return_code>\" [\"<post_action>\"]]]]]] " "|| addinput [<hook>] || input|output|recreate <name> || set <name> <option> " "<value> || rename|copy <name> <new_name> || enable|disable|toggle [<name>|-" @@ -15869,6 +15897,12 @@ msgstr "" #, fuzzy msgid "" " list: list triggers (without argument, this list is displayed)\n" +" -o: send list of triggers enabled to buffer (string in English)\n" +" -ol: send list of triggers enabled to buffer (translated string)\n" +" -i: copy list of triggers enabled in command line (for sending to " +"buffer) (string in English)\n" +" -il: copy list of triggers enabled in command line (for sending to " +"buffer) (translated string)\n" " listfull: list triggers with detailed info for each trigger\n" "listdefault: list default triggers\n" " add: add a trigger\n" diff --git a/po/weechat.pot b/po/weechat.pot index bab3b08cb..3156fed13 100644 --- a/po/weechat.pot +++ b/po/weechat.pot @@ -21,7 +21,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2023-07-04 18:42+0200\n" +"POT-Creation-Date: 2023-07-04 21:49+0200\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" @@ -11364,6 +11364,18 @@ msgstr "" msgid "No trigger defined" msgstr "" +msgid "Triggers enabled:" +msgstr "" + +msgid "default" +msgstr "" + +msgid "custom" +msgstr "" + +msgid "No triggers enabled" +msgstr "" + msgid "List of default triggers:" msgstr "" @@ -11502,7 +11514,8 @@ msgid "manage triggers, the Swiss Army knife for WeeChat" msgstr "" msgid "" -"list|listfull|listdefault || add|addoff|addreplace <name> <hook> " +"list [-o|-ol|-i|-il] || listfull || listdefault || add|addoff|addreplace " +"<name> <hook> " "[\"<arguments>\" [\"<conditions>\" [\"<regex>\" [\"<command>\" [\"<return_code>\" [\"<post_action>\"]]]]]] " "|| addinput [<hook>] || input|output|recreate <name> || set <name> <option> " "<value> || rename|copy <name> <new_name> || enable|disable|toggle [<name>|-" @@ -11513,6 +11526,12 @@ msgstr "" msgid "" " list: list triggers (without argument, this list is displayed)\n" +" -o: send list of triggers enabled to buffer (string in English)\n" +" -ol: send list of triggers enabled to buffer (translated string)\n" +" -i: copy list of triggers enabled in command line (for sending to " +"buffer) (string in English)\n" +" -il: copy list of triggers enabled in command line (for sending to " +"buffer) (translated string)\n" " listfull: list triggers with detailed info for each trigger\n" "listdefault: list default triggers\n" " add: add a trigger\n" diff --git a/src/plugins/trigger/trigger-command.c b/src/plugins/trigger/trigger-command.c index b1c0ff575..5ec8dc079 100644 --- a/src/plugins/trigger/trigger-command.c +++ b/src/plugins/trigger/trigger-command.c @@ -288,6 +288,107 @@ trigger_command_list (const char *message, int verbose) } /* + * Sends the list of enabled triggers to the buffer. + */ + +void +trigger_command_list_buffer (struct t_gui_buffer *buffer, + int send_to_buffer, + int translated) +{ + struct t_trigger *ptr_trigger; + char **output, str_pos[16]; + int i, count, length; + + output = weechat_string_dyn_alloc (256); + if (!output) + return; + + count = 0; + for (ptr_trigger = triggers; ptr_trigger; + ptr_trigger = ptr_trigger->next_trigger) + { + if (!weechat_config_boolean (ptr_trigger->options[TRIGGER_OPTION_ENABLED])) + continue; + if (count == 0) + { + weechat_string_dyn_concat ( + output, + (translated) ? _("Triggers enabled:") : "Triggers enabled:", + -1); + weechat_string_dyn_concat (output, " ", -1); + } + if (count > 0) + weechat_string_dyn_concat (output, ", ", -1); + weechat_string_dyn_concat (output, ptr_trigger->name, -1); + weechat_string_dyn_concat (output, " (", -1); + weechat_string_dyn_concat ( + output, + weechat_config_string (ptr_trigger->options[TRIGGER_OPTION_HOOK]), + -1); + for (i = 0; trigger_config_default_list[i][0]; i++) + { + if (strcmp (trigger_config_default_list[i][0], ptr_trigger->name) == 0) + break; + } + if (trigger_config_default_list[i][0]) + { + weechat_string_dyn_concat (output, ", ", -1); + weechat_string_dyn_concat ( + output, + (translated) ? _("default") : "default", + -1); + if ((weechat_strcmp ( + weechat_config_string (ptr_trigger->options[TRIGGER_OPTION_HOOK]), + trigger_config_default_list[i][TRIGGER_OPTION_HOOK + 1]) != 0) + || (weechat_strcmp ( + weechat_config_string (ptr_trigger->options[TRIGGER_OPTION_ARGUMENTS]), + trigger_config_default_list[i][TRIGGER_OPTION_ARGUMENTS + 1]) != 0) + || (weechat_strcmp ( + weechat_config_string (ptr_trigger->options[TRIGGER_OPTION_CONDITIONS]), + trigger_config_default_list[i][TRIGGER_OPTION_CONDITIONS + 1]) != 0) + || (weechat_strcmp ( + weechat_config_string (ptr_trigger->options[TRIGGER_OPTION_REGEX]), + trigger_config_default_list[i][TRIGGER_OPTION_REGEX + 1]) != 0) + || (weechat_strcmp ( + weechat_config_string (ptr_trigger->options[TRIGGER_OPTION_COMMAND]), + trigger_config_default_list[i][TRIGGER_OPTION_COMMAND + 1]) != 0)) + { + weechat_string_dyn_concat (output, ", ", -1); + weechat_string_dyn_concat ( + output, + (translated) ? _("custom") : "custom", + -1); + } + } + weechat_string_dyn_concat (output, ")", -1); + count++; + } + + if (count == 0) + { + weechat_string_dyn_concat ( + output, + (translated) ? _("No triggers enabled") : "No triggers enabled", + -1); + } + + if (send_to_buffer) + { + weechat_command (buffer, *output); + } + else + { + weechat_buffer_set (buffer, "input", *output); + length = weechat_utf8_strlen (*output); + snprintf (str_pos, sizeof (str_pos), "%d", length); + weechat_buffer_set (buffer, "input_pos", str_pos); + } + + weechat_string_dyn_free (output, 1); +} + +/* * Displays a list of default triggers. */ @@ -523,21 +624,37 @@ trigger_command_trigger (const void *pointer, void *data, /* list all triggers */ if ((argc == 1) - || ((argc == 2) && (weechat_strcmp (argv[1], "list") == 0))) + || ((argc > 1) && (weechat_strcmp (argv[1], "list") == 0))) { - trigger_command_list (_("List of triggers:"), 0); + if (argc > 2) + { + if (weechat_strcmp (argv[2], "-i") == 0) + trigger_command_list_buffer (buffer, 0, 0); + else if (weechat_strcmp (argv[2], "-il") == 0) + trigger_command_list_buffer (buffer, 0, 1); + else if (weechat_strcmp (argv[2], "-o") == 0) + trigger_command_list_buffer (buffer, 1, 0); + else if (weechat_strcmp (argv[2], "-ol") == 0) + trigger_command_list_buffer (buffer, 1, 1); + else + trigger_command_list (_("List of triggers:"), 0); + } + else + { + trigger_command_list (_("List of triggers:"), 0); + } goto end; } /* full list of all triggers */ - if ((argc == 2) && (weechat_strcmp (argv[1], "listfull") == 0)) + if (weechat_strcmp (argv[1], "listfull") == 0) { trigger_command_list (_("List of triggers:"), 1); goto end; } /* list of default triggers */ - if ((argc == 2) && (weechat_strcmp (argv[1], "listdefault") == 0)) + if (weechat_strcmp (argv[1], "listdefault") == 0) { trigger_command_list_default (1); goto end; @@ -1196,7 +1313,9 @@ trigger_command_init () weechat_hook_command ( "trigger", N_("manage triggers, the Swiss Army knife for WeeChat"), - N_("list|listfull|listdefault" + N_("list [-o|-ol|-i|-il]" + " || listfull" + " || listdefault" " || add|addoff|addreplace <name> <hook> [\"<arguments>\" " "[\"<conditions>\" [\"<regex>\" [\"<command>\" " "[\"<return_code>\" [\"<post_action>\"]]]]]]" @@ -1212,6 +1331,12 @@ trigger_command_init () " || default -yes" " || monitor [<filter>]"), N_(" list: list triggers (without argument, this list is displayed)\n" + " -o: send list of triggers enabled to buffer (string in English)\n" + " -ol: send list of triggers enabled to buffer (translated string)\n" + " -i: copy list of triggers enabled in command line (for " + "sending to buffer) (string in English)\n" + " -il: copy list of triggers enabled in command line (for " + "sending to buffer) (translated string)\n" " listfull: list triggers with detailed info for each trigger\n" "listdefault: list default triggers\n" " add: add a trigger\n" @@ -1308,7 +1433,9 @@ trigger_command_init () " open trigger monitor and show only modifiers and triggers whose " "name starts with \"resize\":\n" " /trigger monitor @modifier,resize*"), - "list|listfull|listdefault" + "list -i|-il|-o|-ol" + " || listfull" + " || listdefault" " || add|addoff|addreplace %(trigger_add_arguments)|%*" " || addinput %(trigger_hooks)" " || input|output|recreate %(trigger_names)" |