summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorSébastien Helleu <flashcode@flashtux.org>2020-04-12 09:30:56 +0200
committerSébastien Helleu <flashcode@flashtux.org>2020-04-12 09:30:56 +0200
commit8bdd540df72c3a609e9d51a5c52cf2d65f96d79b (patch)
treef448d1bcda0cdb4769dd87abaa42c5cf06407ced /doc
parentc9329f6fb1805da4c18cdcb1d4da3077bd434ed9 (diff)
downloadweechat-8bdd540df72c3a609e9d51a5c52cf2d65f96d79b.zip
trigger: evaluate arguments of command when the trigger is created (closes #1472)
Diffstat (limited to 'doc')
-rw-r--r--doc/de/autogen/user/trigger_commands.adoc114
-rw-r--r--doc/de/weechat_user.de.adoc12
-rw-r--r--doc/en/autogen/user/trigger_commands.adoc2
-rw-r--r--doc/en/weechat_user.en.adoc11
-rw-r--r--doc/fr/autogen/user/trigger_commands.adoc2
-rw-r--r--doc/fr/weechat_user.fr.adoc11
-rw-r--r--doc/it/autogen/user/trigger_commands.adoc2
-rw-r--r--doc/it/weechat_user.it.adoc11
-rw-r--r--doc/ja/autogen/user/trigger_commands.adoc116
-rw-r--r--doc/ja/weechat_user.ja.adoc12
-rw-r--r--doc/pl/autogen/user/trigger_commands.adoc114
-rw-r--r--doc/pl/weechat_user.pl.adoc12
12 files changed, 214 insertions, 205 deletions
diff --git a/doc/de/autogen/user/trigger_commands.adoc b/doc/de/autogen/user/trigger_commands.adoc
index 0de67d1dc..0fb52a275 100644
--- a/doc/de/autogen/user/trigger_commands.adoc
+++ b/doc/de/autogen/user/trigger_commands.adoc
@@ -20,69 +20,69 @@
default -yes
monitor [<filter>]
- list: zeigt eine Liste aller Trigger (ohne Angabe von Argumente wird diese Liste standardmäßig ausgegeben)
- listfull: zeigt eine detaillierte Liste, mit zusätzlichen Informationen, aller Trigger an
-listdefault: zeigt die standardmäßig genutzten Trigger an
- add: fügt einen Trigger hinzu
- addoff: fügt einen Trigger hinzu (deaktiviert)
- addreplace: erzeugt neuen Trigger oder ersetzt einen schon existierenden Trigger
- name: Name des Trigger
+ list: list triggers (without argument, this list is displayed)
+ listfull: list triggers with detailed info for each trigger
+listdefault: list default triggers
+ add: add a trigger
+ addoff: add a trigger (disabled)
+ addreplace: add or replace an existing trigger
+ name: name of trigger
hook: signal, hsignal, modifier, line, print, command, command_run, timer, config, focus, info, info_hashtable
- arguments: Argumente für den Hook, abhängig vom genutzten Hook (getrennt durch Semikolon):
- signal: Name(en) des signals (erforderlich)
- hsignal: Name(en) des hsignal (erforderlich)
- modifier: Name(en) des modifier (erforderlich)
- line: Buffertyp ("formatted", "free" oder "*"), Liste von Buffermasken, Tags
- print: Buffer, Tags, Nachricht, Farben entfernen
- command: Befehl (erforderlich), Beschreibung, Argumente, Beschreibung der Argumente, Vervollständigung
- command_run: Befehl(e) (erforderlich)
- timer: Intervall (erforderlich), Anpassung an Sekunden (erforderlich), maximale Anzahl an Aufrufen
- config: Name der Einstellung (erforderlich)
- focus: Name(n) für sichtbaren Bereich (erforderlich) (z.B. "chat" für Chatbereich)
- info: Name(n) der Information (erforderlich)
- info_hashtable: Name(n) der Information (erforderlich)
- conditions: evaluierte Bedingungen für den Trigger
- regex: einer oder mehrere reguläre Ausdrücke um Zeichenketten in Variablen zu ersetzen
- command: Befehl welcher ausgeführt werden soll (mehrere Befehle müssen durch ";" voneinander getrennt werden)
-return_code: Rückgabewert für Callback (ok (standard), ok_eat, error)
-post_action: Aktion welche nach der Abarbeitung des Triggers ausgeführt werden soll (none (Standardwert), disable, delete)
- addinput: erstellt einen Trigger mit einer standardmäßigen Mustervorlage
- input: kopiert den kompletten Trigger-Befehl in die Eingabezeile
- output: schickt den Trigger-Befehl als Text in den Buffer
- recreate: wie "input", allerdings wird die Einstellung "addreplace" anstelle von "add" genutzt
- set: definiert, innerhalb eines Triggers, eine Einstellung neu
- option: Name einer Einstellung: name, hook, arguments, conditions, regex, command, return_code
- (um Hilfe über eine Einstellung zu erhalten: /help trigger.trigger.<name>.<option>)
- value: neuer Wert für Einstellung
- rename: benennt einen Trigger um
- copy: kopiert einen Trigger
- enable: aktiviert Trigger (ohne Angabe von Argumenten: aktiviert alle Trigger)
- disable: deaktiviert Trigger (ohne Angabe von Argumenten: deaktiviert alle Trigger)
- toggle: de-/aktiviert Trigger (ohne Angabe von Argumenten: de-/aktiviert alle Trigger)
- restart: startet Trigger neu (Hook(s) werden neu erstellt)
- show: zeigt detaillierte Informationen zu einem Trigger (inklusive einer kleinen Statistik)
- del: entfernt einen Trigger
- -all: führt eine Aktion aus, die alle Trigger beinhaltet
- restore: stellt Trigger mit Standardwerten wieder her (funktioniert nur bei vorgegebenen Triggern)
- default: stellt die standardmäßigen Trigger wieder her
- monitor: öffnet den Trigger Monitor-Buffer, mit optionaler Filterfunktion:
- Filter: zeigt Hooks/Trigger an (ein Hook muss mit "@" beginnen, zum Beispiel "@signal"), mehrere Filter können durch Kommata voneinander getrennt werden; Platzhalter "*" kann im Namen des Trigger verwendet werden
+ arguments: arguments for the hook, depending on hook (separated by semicolons):
+ signal: name(s) of signal (required)
+ hsignal: name(s) of hsignal (required)
+ modifier: name(s) of modifier (required)
+ line: buffer type ("formatted", "free" or "*"), list of buffer masks, tags
+ print: buffer, tags, message, strip colors
+ command: command (required), description, arguments, description of arguments, completion (all arguments except command are evaluated, see /help eval)
+ command_run: command(s) (required)
+ timer: interval (required), align on second, max calls
+ config: name(s) of option (required)
+ focus: name(s) of area (required)
+ info: name(s) of info (required)
+ info_hashtable: name(s) of info (required)
+ conditions: evaluated conditions for the trigger
+ regex: one or more regular expressions to replace strings in variables
+ command: command to execute (many commands can be separated by ";")
+return_code: return code in callback (ok (default), ok_eat, error)
+post_action: action to take after execution (none (default), disable, delete)
+ addinput: set input with default arguments to create a trigger
+ input: set input with the command used to create the trigger
+ output: send the command to create the trigger on the buffer
+ recreate: same as "input", with option "addreplace" instead of "add"
+ set: set an option in a trigger
+ option: name of option: name, hook, arguments, conditions, regex, command, return_code
+ (for help on option, you can type: /help trigger.trigger.<name>.<option>)
+ value: new value for the option
+ rename: rename a trigger
+ copy: copy a trigger
+ enable: enable trigger(s) (without arguments: enable triggers globally)
+ disable: disable trigger(s) (without arguments: disable triggers globally)
+ toggle: toggle trigger(s) (without arguments: toggle triggers globally)
+ restart: restart trigger(s) (recreate the hooks)
+ show: show detailed info on a trigger (with some stats)
+ del: delete a trigger
+ -all: do action on all triggers
+ restore: restore trigger(s) with the default values (works only for default triggers)
+ default: delete all triggers and restore default ones
+ monitor: open the trigger monitor buffer, with optional filter:
+ 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
-Wenn ein Trigger-Callback aufgerufen wird, dann wird folgende Befehlskette ausgeführt:
- 1. Überprüfung von Bedingungen; falls unwahr, beenden
- 2. ersetze Text mittels einem oder mehreren erweiterten regulären POSIX Ausdrücken (sofern im Trigger definiert)
- 3. ein oder mehrere Befehle werden ausgeführt (sofern im Trigger definiert)
- 4. Beendigung mit einem Rückgabewert (ausgenommen sind modifiers, line, focus, info und info_hashtable)
- 5. Aktion welche nach der Abarbeitung des Triggers ausgeführt werden soll
+When a trigger callback is called, following actions are performed, in this order:
+ 1. check conditions; if false, exit
+ 2. replace text using POSIX extended regular expression(s) (if defined in trigger)
+ 3. execute command(s) (if defined in trigger)
+ 4. exit with a return code (except for modifier, line, focus, info and info_hashtable)
+ 5. perform post action
-Beispiele (die standardmäßig verfügbaren Trigger kann man sich mit "/trigger listdefault" anzeigen lassen):
- fügt einer Nachricht die Textattribute *fett*, _unterstrichen_ und /kursiv/ hinzu:
+Examples (you can also look at default triggers with /trigger listdefault):
+ add text attributes *bold*, _underline_ and /italic/ (only in user messages):
/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}/"
- verbirgt die Nicklist auf kleineren Terminals:
+ hide nicklist bar on small terminals:
/trigger add resize_small signal signal_sigwinch "${info:term_width} < 100" "" "/bar hide nicklist"
/trigger add resize_big signal signal_sigwinch "${info:term_width} >= 100" "" "/bar show nicklist"
- speichert die Konfiguration jede Stunde ab:
+ silently save config each hour:
/trigger add cfgsave timer 3600000;0;0 "" "" "/mute /save"
- öffnet den Trigger Monitor und zeigt ausschließlich modifier und Trigger an, die mit "resize" im Namen beginnen:
+ open trigger monitor and show only modifiers and triggers whose name starts with "resize":
/trigger monitor @modifier,resize*
----
diff --git a/doc/de/weechat_user.de.adoc b/doc/de/weechat_user.de.adoc
index 2d7fc95af..ab5aa8863 100644
--- a/doc/de/weechat_user.de.adoc
+++ b/doc/de/weechat_user.de.adoc
@@ -3923,14 +3923,16 @@ ein Semikolon getrennt.
`+*;;;1+` |
link:weechat_plugin_api.en.html#_hook_print[hook_print] (Englisch)
+// TRANSLATION MISSING
| command |
1. Befehlsname (Priorität erlaubt) (erforderlich) +
- 2. Beschreibung +
- 3. Argumente +
- 4. Beschreibung der Argumente +
- 5. Vervollständigung |
+ 2. Beschreibung (evaluated, siehe Befehl <<command_weechat_eval,/eval>>) +
+ 3. Argumente (evaluated, siehe Befehl <<command_weechat_eval,/eval>>) +
+ 4. Beschreibung der Argumente (evaluated, siehe Befehl <<command_weechat_eval,/eval>>) +
+ 5. Vervollständigung (evaluated, siehe Befehl <<command_weechat_eval,/eval>>) |
`+test+` +
- `+5000\|test+` |
+ `+5000\|test+` +
+ `+test;test command;arg1 arg2;arg1: description 1${\n}arg2: description 2+` |
link:weechat_plugin_api.en.html#_hook_command[hook_command] (Englisch)
| command_run |
diff --git a/doc/en/autogen/user/trigger_commands.adoc b/doc/en/autogen/user/trigger_commands.adoc
index 2c24cb6f2..2b6c772dc 100644
--- a/doc/en/autogen/user/trigger_commands.adoc
+++ b/doc/en/autogen/user/trigger_commands.adoc
@@ -34,7 +34,7 @@ listdefault: list default triggers
modifier: name(s) of modifier (required)
line: buffer type ("formatted", "free" or "*"), list of buffer masks, tags
print: buffer, tags, message, strip colors
- command: command (required), description, arguments, description of arguments, completion
+ command: command (required), description, arguments, description of arguments, completion (all arguments except command are evaluated, see /help eval)
command_run: command(s) (required)
timer: interval (required), align on second, max calls
config: name(s) of option (required)
diff --git a/doc/en/weechat_user.en.adoc b/doc/en/weechat_user.en.adoc
index 8d902e69a..12148c1a9 100644
--- a/doc/en/weechat_user.en.adoc
+++ b/doc/en/weechat_user.en.adoc
@@ -3839,12 +3839,13 @@ The arguments depend on the hook used. They are separated by semicolons.
| command |
1. command name (priority allowed) (required) +
- 2. description +
- 3. arguments +
- 4. description of arguments +
- 5. completion |
+ 2. description (evaluated, see command <<command_weechat_eval,/eval>>) +
+ 3. arguments (evaluated, see command <<command_weechat_eval,/eval>>) +
+ 4. description of arguments (evaluated, see command <<command_weechat_eval,/eval>>) +
+ 5. completion (evaluated, see command <<command_weechat_eval,/eval>>) |
`+test+` +
- `+5000\|test+` |
+ `+5000\|test+` +
+ `+test;test command;arg1 arg2;arg1: description 1${\n}arg2: description 2+` |
link:weechat_plugin_api.en.html#_hook_command[hook_command]
| command_run |
diff --git a/doc/fr/autogen/user/trigger_commands.adoc b/doc/fr/autogen/user/trigger_commands.adoc
index b98d54306..b7a57a761 100644
--- a/doc/fr/autogen/user/trigger_commands.adoc
+++ b/doc/fr/autogen/user/trigger_commands.adoc
@@ -34,7 +34,7 @@ listdefault : lister les triggers par défaut
modifier : nom(s) de modificateur (obligatoire)
line : type de tampon ("formatted", "free" ou "*"), liste de masques de tampons, étiquettes
print : tampon, étiquettes, message, suppression des couleurs (0/1)
- command : commande (obligatoire), description, paramètres, description des paramètres, complétion
+ command : commande (obligatoire), description, paramètres, description des paramètres, complétion (tous les paramètres sauf la commande sont évalués, voir /help eval)
command_run : commande(s) (obligatoire)
timer : intervalle (obligatoire), alignement sur la seconde, nombre max d'appels
config : nom(s) de l'option (obligatoire)
diff --git a/doc/fr/weechat_user.fr.adoc b/doc/fr/weechat_user.fr.adoc
index 3c3880297..062f32829 100644
--- a/doc/fr/weechat_user.fr.adoc
+++ b/doc/fr/weechat_user.fr.adoc
@@ -3965,12 +3965,13 @@ points-virgules.
| command |
1. nom de commande (priorité autorisée) (obligatoire) +
- 2. description +
- 3. paramètres +
- 4. description des paramètres +
- 5. complétion |
+ 2. description (évalué, voir la commande <<command_weechat_eval,/eval>>) +
+ 3. paramètres (évalué, voir la commande <<command_weechat_eval,/eval>>) +
+ 4. description des paramètres (évalué, voir la commande <<command_weechat_eval,/eval>>) +
+ 5. complétion (évalué, voir la commande <<command_weechat_eval,/eval>>) |
`+test+` +
- `+5000\|test+` |
+ `+5000\|test+` +
+ `+test;commande de test;arg1 arg2;arg1: description 1${\n}arg2: description 2+` |
link:weechat_plugin_api.fr.html#_hook_command[hook_command]
| command_run |
diff --git a/doc/it/autogen/user/trigger_commands.adoc b/doc/it/autogen/user/trigger_commands.adoc
index 2c24cb6f2..2b6c772dc 100644
--- a/doc/it/autogen/user/trigger_commands.adoc
+++ b/doc/it/autogen/user/trigger_commands.adoc
@@ -34,7 +34,7 @@ listdefault: list default triggers
modifier: name(s) of modifier (required)
line: buffer type ("formatted", "free" or "*"), list of buffer masks, tags
print: buffer, tags, message, strip colors
- command: command (required), description, arguments, description of arguments, completion
+ command: command (required), description, arguments, description of arguments, completion (all arguments except command are evaluated, see /help eval)
command_run: command(s) (required)
timer: interval (required), align on second, max calls
config: name(s) of option (required)
diff --git a/doc/it/weechat_user.it.adoc b/doc/it/weechat_user.it.adoc
index 7637aa7e7..29650f526 100644
--- a/doc/it/weechat_user.it.adoc
+++ b/doc/it/weechat_user.it.adoc
@@ -4131,12 +4131,13 @@ The arguments depend on the hook used. They are separated by semicolons.
| command |
1. command name (priority allowed) (required) +
- 2. description +
- 3. arguments +
- 4. description of arguments +
- 5. completion |
+ 2. description (evaluated, see command <<command_weechat_eval,/eval>>) +
+ 3. arguments (evaluated, see command <<command_weechat_eval,/eval>>) +
+ 4. description of arguments (evaluated, see command <<command_weechat_eval,/eval>>) +
+ 5. completion (evaluated, see command <<command_weechat_eval,/eval>>) |
`+test+` +
- `+5000\|test+` |
+ `+5000\|test+` +
+ `+test;test command;arg1 arg2;arg1: description 1${\n}arg2: description 2+` |
link:weechat_plugin_api.it.html#_hook_command[hook_command]
| command_run |
diff --git a/doc/ja/autogen/user/trigger_commands.adoc b/doc/ja/autogen/user/trigger_commands.adoc
index b18b82183..776b15433 100644
--- a/doc/ja/autogen/user/trigger_commands.adoc
+++ b/doc/ja/autogen/user/trigger_commands.adoc
@@ -20,69 +20,69 @@
default -yes
monitor [<filter>]
- list: トリガをリストアップ (引数なしの場合、このリストを表示します)
- listfull: 各トリガに関する詳細な情報を付けてトリガをリストアップ
-listdefault: デフォルトトリガをリストアップ
- add: トリガを追加
- addoff: トリガを追加 (無効状態で)
- addreplace: 追加または存在するトリガを置換
- name: トリガの名前
- hook: signal、hsignal、modifier、line、print、command、command_run、timer、config、focus、info、info_hashtable
- arguments: フックの引数、フックの種類に依存 (セミコロンで区切る):
- signal: シグナルの名前 (必須)
- hsignal: hsignal の名前 (必須)
- modifier: modifier の名前 (必須)
- line: バッファ型 ("formatted"、"free"、"*")、バッファマスクおよびタグのリスト
- print: バッファ、タグ、メッセージ、色の削除
- command: コマンド (必須)、説明、引数、引数の説明、補完
- command_run: コマンド (必須)
- timer: インターバル (必須)、秒の調節、最大呼び出し回数
- config: オプションの名前 (必須)
- focus: エリアの名前 (必須)
- info: インフォ名 (必須)
- info_hashtable: インフォ名 (必須)
- conditions: トリガの実行条件
- regex: 変数内の文字列を置換する 1 つ以上の正規表現
- command: 実行するコマンド (複数のコマンドは ";" で区切ってください)
-return_code: コールバック内のリターンコード (ok (デフォルト)、ok_eat、error)
-post_action: トリガ実行後の処遇 (none (デフォルト、何もしない)、disable (無効化)、delete (削除))
- addinput: 入力にトリガを作る際のデフォルト引数を設定
- input: 入力にトリガを作る際に使われるコマンドを設定
- output: バッファでトリガを作る際のコマンドを送信
- recreate: "add" の代わりに "addreplace" オプションを使うことを除いて "input" と同じ
- set: トリガにオプションを設定
- option: オプションの名前: name、hook、arguments、conditions、regex、command、return_code
- (オプションに関するヘルプを見るには: /help trigger.trigger.<name>.<option>)
- value: オプションの新しい値
- rename: トリガの名前を変更
- copy: トリガをコピー
- enable: トリガを有効化 (引数なしの場合: 大域的にトリガを有効化)
- disable: トリガを無効化 (引数なしの場合: 大域的にトリガを無効化)
- toggle: トリガの有効無効を切り替え (引数なしの場合: 大域的にトリガの有効無効を切り替え)
- restart: トリガの再開 (フックを再作成)
- show: トリガに関する情報を表示 (状態を含めて)
- del: トリガを削除
- -all: 全てのトリガに関するアクションを実行
- restore: デフォルトの値でトリガを復元 (これができるのはデフォルトトリガに限ります)
- default: 全てのトリガを削除してデフォルトのトリガを復元
- monitor: 任意でフィルタを付けてトリガ監視バッファを開く:
- filter: フックおよびトリガをフィルタして表示 (フックは必ず "@" で始めてください、たとえば "@signal")、複数のフィルタをかける場合はそれぞれをコンマで区切ってください; 各トリガ名にワイルドカード "*" を使うことができます。
+ list: list triggers (without argument, this list is displayed)
+ listfull: list triggers with detailed info for each trigger
+listdefault: list default triggers
+ add: add a trigger
+ addoff: add a trigger (disabled)
+ addreplace: add or replace an existing trigger
+ name: name of trigger
+ hook: signal, hsignal, modifier, line, print, command, command_run, timer, config, focus, info, info_hashtable
+ arguments: arguments for the hook, depending on hook (separated by semicolons):
+ signal: name(s) of signal (required)
+ hsignal: name(s) of hsignal (required)
+ modifier: name(s) of modifier (required)
+ line: buffer type ("formatted", "free" or "*"), list of buffer masks, tags
+ print: buffer, tags, message, strip colors
+ command: command (required), description, arguments, description of arguments, completion (all arguments except command are evaluated, see /help eval)
+ command_run: command(s) (required)
+ timer: interval (required), align on second, max calls
+ config: name(s) of option (required)
+ focus: name(s) of area (required)
+ info: name(s) of info (required)
+ info_hashtable: name(s) of info (required)
+ conditions: evaluated conditions for the trigger
+ regex: one or more regular expressions to replace strings in variables
+ command: command to execute (many commands can be separated by ";")
+return_code: return code in callback (ok (default), ok_eat, error)
+post_action: action to take after execution (none (default), disable, delete)
+ addinput: set input with default arguments to create a trigger
+ input: set input with the command used to create the trigger
+ output: send the command to create the trigger on the buffer
+ recreate: same as "input", with option "addreplace" instead of "add"
+ set: set an option in a trigger
+ option: name of option: name, hook, arguments, conditions, regex, command, return_code
+ (for help on option, you can type: /help trigger.trigger.<name>.<option>)
+ value: new value for the option
+ rename: rename a trigger
+ copy: copy a trigger
+ enable: enable trigger(s) (without arguments: enable triggers globally)
+ disable: disable trigger(s) (without arguments: disable triggers globally)
+ toggle: toggle trigger(s) (without arguments: toggle triggers globally)
+ restart: restart trigger(s) (recreate the hooks)
+ show: show detailed info on a trigger (with some stats)
+ del: delete a trigger
+ -all: do action on all triggers
+ restore: restore trigger(s) with the default values (works only for default triggers)
+ default: delete all triggers and restore default ones
+ monitor: open the trigger monitor buffer, with optional filter:
+ 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
-トリガコールバックを呼び出す際には、以下の順番通りにアクションを実行します:
- 1. 条件を確認; 偽の場合、終了
- 2. POSIX 拡張正規表現を使ってテキストを置換 (トリガに定義されている場合)
- 3. コマンドを実行 (トリガに定義されている場合)
- 4. リターンコードを返して終了 (modifier、line、focus、info、info_hashtable を除く)
- 5. トリガ実行後の処遇を適用
+When a trigger callback is called, following actions are performed, in this order:
+ 1. check conditions; if false, exit
+ 2. replace text using POSIX extended regular expression(s) (if defined in trigger)
+ 3. execute command(s) (if defined in trigger)
+ 4. exit with a return code (except for modifier, line, focus, info and info_hashtable)
+ 5. perform post action
-例 (/trigger listdefault でデフォルトトリガを見ることができます):
- テキスト属性 *太字*、_下線_、/イタリック/ を追加 (ユーザメッセージのみ):
+Examples (you can also look at default triggers with /trigger listdefault):
+ add text attributes *bold*, _underline_ and /italic/ (only in user messages):
/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}/"
- 狭い端末ではニックネームリストバーを隠す:
+ hide nicklist bar on small terminals:
/trigger add resize_small signal signal_sigwinch "${info:term_width} < 100" "" "/bar hide nicklist"
/trigger add resize_big signal signal_sigwinch "${info:term_width} >= 100" "" "/bar show nicklist"
- 設定を 1 時間毎に黙々と保存:
+ silently save config each hour:
/trigger add cfgsave timer 3600000;0;0 "" "" "/mute /save"
- トリガモニタを開き、修飾子と名前が "resize" から始まるトリガだけを表示:
+ open trigger monitor and show only modifiers and triggers whose name starts with "resize":
/trigger monitor @modifier,resize*
----
diff --git a/doc/ja/weechat_user.ja.adoc b/doc/ja/weechat_user.ja.adoc
index 19ece8c40..9c80a652d 100644
--- a/doc/ja/weechat_user.ja.adoc
+++ b/doc/ja/weechat_user.ja.adoc
@@ -3866,14 +3866,16 @@ trigger.trigger.beep.post_action = none
`+*;;;1+` |
link:weechat_plugin_api.ja.html#_hook_print[hook_print]
+// TRANSLATION MISSING
| command |
1. コマンド名 (優先度の指定も可) (必須) +
- 2. 説明 +
- 3. 引数 +
- 4. 引数の説明 +
- 5. 補完 |
+ 2. 説明 (evaluated, <<command_weechat_eval,/eval>> コマンドを参照) +
+ 3. 引数 (evaluated, <<command_weechat_eval,/eval>> コマンドを参照) +
+ 4. 引数の説明 (evaluated, <<command_weechat_eval,/eval>> コマンドを参照) +
+ 5. 補完 (evaluated, <<command_weechat_eval,/eval>> コマンドを参照) |
`+test+` +
- `+5000\|test+` |
+ `+5000\|test+` +
+ `+test;test command;arg1 arg2;arg1: description 1${\n}arg2: description 2+` |
link:weechat_plugin_api.ja.html#_hook_command[hook_command]
| command_run |
diff --git a/doc/pl/autogen/user/trigger_commands.adoc b/doc/pl/autogen/user/trigger_commands.adoc
index 8397f4fdd..a752ca9e9 100644
--- a/doc/pl/autogen/user/trigger_commands.adoc
+++ b/doc/pl/autogen/user/trigger_commands.adoc
@@ -20,69 +20,69 @@
default -yes
monitor [<filtr>]
- list: lista triggerów (jeśli nie podano argumentu, wyświetli się ta lista)
- listfull: lista triggerów ze szczegółowymi informacjami
-listdefault: lista domyślnych triggerów
- add: dodaje trigger
- addoff: dodaje trigger (wyłączony)
- addreplace: dodaje lub zastępuje istniejący trigger
- nazwa: nazwa triggera
+ list: list triggers (without argument, this list is displayed)
+ listfull: list triggers with detailed info for each trigger
+listdefault: list default triggers
+ add: add a trigger
+ addoff: add a trigger (disabled)
+ addreplace: add or replace an existing trigger
+ name: name of trigger
hook: signal, hsignal, modifier, line, print, command, command_run, timer, config, focus, info, info_hashtable
- argumenty: argumenty dla uchwytu, w zależności od jego typu (oddzielone średnikami):
- signal: nazwa(-y) signal (wymagane)
- hsignal: nazwa(-y) hsignal (wymagane)
- modifier: nazwa(-y) modifier (wymagane)
- line: typ bufora("formatted", "free" lub "*"), lista mask buforów, tagi
- print: bufor, tagi, wiadomość, pomiń kolory
- command: komenda (wymagane), opis, argumenty, opis argumentów, dopełnienie
- command_run: komenda(-y) (wymagane)
- timer: interwał (wymagane), wyrównanie sekund, ilość wywołań
- config: nazwa(-y) opcji (wymagane)
- focus: nazwa(-y) obszarów (wymagane)
- info: nazwa(y) informacji (wymagane)
- info_hashtable: nazwa(y) informacji (wymagane)
- warunki: przetwarzane warunki dla triggera
- regex: jedno lub więcej wyrażeń regularnych do zastępowania ciągów w zmiennych
- komenda: komenda do wykonania (wiele komend można oddzielić ";")
-zwracany_kod: kod zwracany w callbacku (ok (domyślne), ok_eat, error)
-post_action: akcja do wykonania po zakończeniu (none (domyślne), disable, delete)
- addinput: ustawia wejście z domyślnymi argumentami do stworzenia triggera
- input: ustawia wejście z komendą użytą do stworzenia triggera
- output: wysyła komendę do stworzenia triggera do buforu
- recreate: tak samo jak "input", z opcją "addreplace" zamiast "add"
- set: ustawia opcje triggera
- opcja: nazwa opcji: name, hook, arguments, conditions, regex, command, return_code
- (aby uzyskać pomoc na temat opcji możesz wpisać: /help trigger.trigger.<nazwa>.<opcja>)
- wartość: nowa wartość dla opcji
- rename: zmienia nazwę triggera
- copy: kopiuje trigger
- enable: włącza trigger(y) (bez argumentów: włącza triggery globalnie)
- disable: wyłącza trigger(y) (bez argumentów: wyłącza triggery globalnie)
- toggle: zmienia stan triggera(-ów) (bez argumentów: zmienia stan triggerów globalnie)
- restart: restartuje trigger(y) (tworzy na nowo uchwyty)
- show: pokazuje szczegółowe informacje o triggerze (z niektórymi statystykami)
- del: usuwa trigger
- -all: wykonaj akcję na wszystkich triggerach
- restore: przywraca trigger(y) z domyślnymi wartościami (działa tylko dla domyślnych triggerów)
- default: przywraca domyślne triggery
- monitor: otwiera bufor monitorowania triggerów, z opcjonalnym filtrem:
- filtr: filtruje uchwyty/triggery do wyświetlenia (uchwyt musi się zaczynać od "@", na przykład "@signal"), wiele filtrów może być oddzielonych przecinkiem; dzika karta "*" jest dozwolona w nazwie każdego triggera
+ arguments: arguments for the hook, depending on hook (separated by semicolons):
+ signal: name(s) of signal (required)
+ hsignal: name(s) of hsignal (required)
+ modifier: name(s) of modifier (required)
+ line: buffer type ("formatted", "free" or "*"), list of buffer masks, tags
+ print: buffer, tags, message, strip colors
+ command: command (required), description, arguments, description of arguments, completion (all arguments except command are evaluated, see /help eval)
+ command_run: command(s) (required)
+ timer: interval (required), align on second, max calls
+ config: name(s) of option (required)
+ focus: name(s) of area (required)
+ info: name(s) of info (required)
+ info_hashtable: name(s) of info (required)
+ conditions: evaluated conditions for the trigger
+ regex: one or more regular expressions to replace strings in variables
+ command: command to execute (many commands can be separated by ";")
+return_code: return code in callback (ok (default), ok_eat, error)
+post_action: action to take after execution (none (default), disable, delete)
+ addinput: set input with default arguments to create a trigger
+ input: set input with the command used to create the trigger
+ output: send the command to create the trigger on the buffer
+ recreate: same as "input", with option "addreplace" instead of "add"
+ set: set an option in a trigger
+ option: name of option: name, hook, arguments, conditions, regex, command, return_code
+ (for help on option, you can type: /help trigger.trigger.<name>.<option>)
+ value: new value for the option
+ rename: rename a trigger
+ copy: copy a trigger
+ enable: enable trigger(s) (without arguments: enable triggers globally)
+ disable: disable trigger(s) (without arguments: disable triggers globally)
+ toggle: toggle trigger(s) (without arguments: toggle triggers globally)
+ restart: restart trigger(s) (recreate the hooks)
+ show: show detailed info on a trigger (with some stats)
+ del: delete a trigger
+ -all: do action on all triggers
+ restore: restore trigger(s) with the default values (works only for default triggers)
+ default: delete all triggers and restore default ones
+ monitor: open the trigger monitor buffer, with optional filter:
+ 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
-Kiedy callback triggera jest wywoływany, wykonywane są następujące akcje, w kolejności:
- 1. sprawdzenie warunków; jeśli nie są spełnione, wyjście
- 2. zastąpienie tekstu za pomocą rozszerzonych wyrażeń regularnych POSIX (jeśli zdefiniowane)
- 3. wykonanie komend(y) (jeśli zdefiniowane)
- 4. wyjście z kodem wyjścia (poza modifiers i focus)
- 5. wykonanie akcji kończącej
+When a trigger callback is called, following actions are performed, in this order:
+ 1. check conditions; if false, exit
+ 2. replace text using POSIX extended regular expression(s) (if defined in trigger)
+ 3. execute command(s) (if defined in trigger)
+ 4. exit with a return code (except for modifier, line, focus, info and info_hashtable)
+ 5. perform post action
-Przykłady (możesz też spojrzeć na domyślne triggery za pomocą /trigger listdefault):
- dodaje atrybuty tekstu *bold*, _underline_ i /italic/ (tylko w wiadomościach użytkowników):
+Examples (you can also look at default triggers with /trigger listdefault):
+ add text attributes *bold*, _underline_ and /italic/ (only in user messages):
/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}/"
- ukrywa pasek z nickami na małych terminalach:
+ hide nicklist bar on small terminals:
/trigger add resize_small signal signal_sigwinch "${info:term_width} < 100" "" "/bar hide nicklist"
/trigger add resize_big signal signal_sigwinch "${info:term_width} >= 100" "" "/bar show nicklist"
- cichy zapis plików konfiguracyjnych co każdą godzinę:
+ silently save config each hour:
/trigger add cfgsave timer 3600000;0;0 "" "" "/mute /save"
- otwiera monitor triggerów i pokazuje tylko modifiers i triggery, których nazwa zaczyna się od "resize":
+ open trigger monitor and show only modifiers and triggers whose name starts with "resize":
/trigger monitor @modifier,resize*
----
diff --git a/doc/pl/weechat_user.pl.adoc b/doc/pl/weechat_user.pl.adoc
index ce58770f5..f331cd4e4 100644
--- a/doc/pl/weechat_user.pl.adoc
+++ b/doc/pl/weechat_user.pl.adoc
@@ -3864,14 +3864,16 @@ Argumenty zależą od rodzaju uchwytu. Są oddzielane średnikami.
`+*;;;1+` |
link:weechat_plugin_api.en.html#_hook_print[hook_print] (Angielski)
+// TRANSLATION MISSING
| command |
1. nazwa komendy dozwolony priorytet) (wymagane) +
- 2. opis +
- 3. argumenty +
- 4. opis argumentów +
- 5. dopełnienie |
+ 2. opis (evaluated, zobacz komendę <<command_weechat_eval,/eval>>) +
+ 3. argumenty (evaluated, zobacz komendę <<command_weechat_eval,/eval>>) +
+ 4. opis argumentów (evaluated, zobacz komendę <<command_weechat_eval,/eval>>) +
+ 5. dopełnienie (evaluated, zobacz komendę <<command_weechat_eval,/eval>>) |
`+test+` +
- `+5000\|test+` |
+ `+5000\|test+` +
+ `+test;test command;arg1 arg2;arg1: description 1${\n}arg2: description 2+` |
link:weechat_plugin_api.en.html#_hook_command[hook_command] (Angielski)
| command_run |