1
0
mirror of https://github.com/weechat/weechat.git synced 2026-06-29 22:36:38 +02:00

core: add creation of user variables in evaluated expressions with ${define:name,value}

This commit is contained in:
Sébastien Helleu
2021-09-18 14:56:25 +02:00
parent bd21b25bad
commit a6826af796
31 changed files with 1698 additions and 1352 deletions
+7
View File
@@ -15,6 +15,13 @@ https://weechat.org/files/releasenotes/ReleaseNotes-devel.html[release notes]
(file _ReleaseNotes.adoc_ in sources).
[[v3.4]]
== Version 3.4 (under dev)
New features::
* api: add user variables in evaluation of expressions with "define:name,value"
[[v3.3]]
== Version 3.3 (2021-09-19)
+114 -111
View File
@@ -1337,123 +1337,126 @@ infolists: zeigt Information über die Infolists an
/eval [-n|-s] [-d] <expression>
[-n] [-d [-d]] -c <expression1> <operator> <expression2>
-n: gibt das Ergebnis aus, ohne dass dieses in den Buffer gesendet wird (debug Modus)
-s: teilt Ausdrücke, bevor sie evaluiert werden (mehrere Befehle können durch Semikolon getrennt werden)
-d: eine Debug-Ausgabe nach Auswertung anzeigen (Nutzung von zwei -d: ausführliche Debug-Ausgabe)
-c: Auswertung als Bedingung: nutzt Operatoren und runde Klammern, Rückgabewert als Boolean-Wert ("0" oder "1")
expression: Ausdruck welcher verarbeitet werden soll. Variablen im Format ${variable} werden ersetzt (siehe unten); mehrere Befehle werden durch ein Semikolon voneinander getrennt
operator: ein logischer oder vergleichender Operand:
- logische Operanden:
&& boolean "und"
|| boolean "oder"
- vergleichende Operanden:
== gleich
!= ungleich
<= kleiner oder gleich
< kleiner
>= größer oder gleich
> größer
=~ stimmt mit regulärem POSIX Ausdruck überein
!~ stimmt NICHT mit regulärem POSIX Ausdruck überein
==* stimmt mit Maske überein (Platzhalter "*" ist erlaubt)
!!* stimmt mit Maske NICHT überein (Platzhalter "*" ist erlaubt)
=* stimmt mit Maske überein, Groß- und Kleinschreibung wird nicht beachtet (Platzhalter "*" ist erlaubt)
!* stimmt mit Maske NICHT überein, Groß- und Kleinschreibung wird nicht beachtet (Platzhalter "*" ist erlaubt)
==- ist enthalten, Groß- und Kleinschreibung wird beachtet
!!- ist NICHT enthalten, Groß- und Kleinschreibung wird beachtet
=- ist enthalten, Groß- und Kleinschreibung wird nicht beachtet
!- ist NICHT enthalten, Groß- und Kleinschreibung wird nicht beachtet
-n: display result without sending it to buffer (debug mode)
-s: split expression before evaluating it (many commands can be separated by semicolons)
-d: display debug output after evaluation (with two -d: more verbose debug)
-c: evaluate as condition: use operators and parentheses, return a boolean value ("0" or "1")
expression: expression to evaluate, variables with format ${variable} are replaced (see below); many commands can be separated by semicolons
operator: a logical or comparison operator:
- logical operators:
&& boolean "and"
|| boolean "or"
- comparison operators:
== equal
!= not equal
<= less or equal
< less
>= greater or equal
> greater
=~ is matching POSIX extended regex
!~ is NOT matching POSIX extended regex
==* is matching mask, case sensitive (wildcard "*" is allowed)
!!* is NOT matching mask, case sensitive (wildcard "*" is allowed)
=* is matching mask, case insensitive (wildcard "*" is allowed)
!* is NOT matching mask, case insensitive (wildcard "*" is allowed)
==- is included, case sensitive
!!- is NOT included, case sensitive
=- is included, case insensitive
!- is NOT included, case insensitive
Ein Ausdruck gilt als "wahr" sofern das Ergebnis weder NULL, nicht leer und von "0" abweichend ist.
Für einen Vergleich werden Fließkommazahlen genutzt, insofern es sich bei beiden Ausdrücken um gültige Zahlen handelt, folgende Formate werden unterstützt:
- Integer (Beispiele: 5, -7)
- Fließkommazahl (Beispiele: 5.2, -7.5, 2.83e-2)
- hexadezimale Zahl (Beispiele: 0xA3, -0xA3)
Um einen Vergleich zwischen zwei Zeichenketten zu erzwingen, müssen die Ausdrücke in Anführungszeichen gesetzt werden, zum Beispiel:
An expression is considered as "true" if it is not NULL, not empty, and different from "0".
The comparison is made using floating point numbers if the two expressions are valid numbers, with one of the following formats:
- integer (examples: 5, -7)
- floating point number (examples: 5.2, -7.5, 2.83e-2)
- hexadecimal number (examples: 0xA3, -0xA3)
To force a string comparison, you can add double quotes around each expression, for example:
50 > 100 ==> 0
"50" > "100" ==> 1
Einige Variablen werden im Ausdruck mittels der Formatierung ${variable} ersetzt. Mögliche Variablen sind, nach Reihenfolge ihrer Priorität:
1. die Zeichenfolge selbst ohne Auswertung (Format: "raw:xxx")\n
2. eine evaluierte Teilzeichenkette (Format: "eval:xxx")
3. eine evaluierte Bedingung (Format: "eval_cond:xxx")
4. eine Zeichenkette mit Escapesequenzen (Format: "esc:xxx" oder "\xxx")
5. Zeichen, die in einer Zeichenkette nicht dargestellt werden sollen (Format: "hide:Zeichen,Zeichenkette")
6. eine Zeichenkette mit einer maximalen Anzahl an Zeichen (Format: "cut:max,suffix,string" oder "cut:+max,suffix,string")
oder maximale Anzahl an Zeichen die auf dem Bildschirm angezeigt werden sollen (Format: "cutscr:Max,Suffix,Zeichenkette oder "cutscr:+Max,Suffix,Zeichenkette")
7. eine Zeichenkette umkehren (Format: "rev:xxx" oder "revscr:xxx")
8. eine Zeichenkette wiederholen (Format: "repeat:Anzahl,Zeichenkette")
9. Länge einer Zeichenkette (Format: "length:xxx" oder "lengthscr:xxx")
10. Aufteilen einer Zeichenkette (Format: "split:Anzahl,Trennzeichen,Flags,xxx")
11. Aufteilen von Shell-Argumenten (Format: "split_shell:Anzahl,xxx")
12. eine Farbe (Format: "color:xxx", siehe "Anleitung für API Erweiterung", Funktion "color")
13. zum modifizieren (Format: "modifier:name,data,string")
14. eine Info (Format: "Info:Name,Argumente", Argumente sind optional)
15. eine Basis 16/32/64 kodierte / dekodierte Zeichenfolge (Format: "base_encode:base,xxx" oder "base_decode:base,xxx")
16. aktuelles Datum/Uhrzeit (Format: "date" oder "date:format")
17. eine Umgebungsvariable (Format: "env:XXX")
18. ein Dreifachoperand (Format: "if:Bedingung?Wert_falls_wahr:Wert_falls_unwahr")
19. Ergebnis eines Ausdrucks mit Klammern und Operatoren + - * / // % ** (Format: "calc:xxx")
20. eine zufällige ganze Zahl (Format: "random:min,max")
21. eine übersetzte Zeichenkette (Format: "translate:xxx")
22. eine Option (Format: "file.section.option")
23. eine lokale Variable eines Buffers
24. ein(e) hdata - Name/Variable (der Wert wird automatisch in eine Zeichenkette konvertiert), standardmäßig wird für "window" und "buffer" das aktuelle Fenster/Buffer verwendet.
Das Format für hdata kann wie folgt aufgebaut sein:
hdata.var1.var2...: startet mit hdata (der Pointer muss bekannt sein) und fragt eine Variable nach der anderen ab (weitere hdata können folgen)
hdata[list].var1.var2...: startet hdata mittels einer Liste, zum Beispiel:
${buffer[gui_buffers].full_name}: der vollständige Name des ersten Buffers, in der verknüpften Liste aller Buffer
${plugin[weechat_plugins].name}: Name der ersten Erweiterung, in der verknüpften Liste aller Erweiterungen
hdata[pointer].var1.var2...: startet hdata mittels einem Pointer, zum Beispiel:
${buffer[0x1234abcd].full_name}: vollständiger Name eines Buffers und des dazugehörigen Pointers (kann in triggern benutzt werden)
${buffer[my_pointer].full_name}: vollständiger Name des Buffers mit dem entsprechenden Pointernamen (kann in Triggern verwendet werden)
Die vorhandenen Namen für hdata und Variablen sind in der "Anleitung für API Erweiterung", Bereich "weechat_hdata_get". beschrieben
Some variables are replaced in expression, using the format ${variable}, variable can be, by order of priority:
1. the string itself without evaluation (format: "raw:xxx")
2. a user-defined variable (format: "name")
3. an evaluated sub-string (format: "eval:xxx")
4. an evaluated condition (format: "eval_cond:xxx")
5. a string with escaped chars (format: "esc:xxx" or "\xxx")
6. a string with chars to hide (format: "hide:char,string")
7. a string with max chars (format: "cut:max,suffix,string" or "cut:+max,suffix,string")
or max chars displayed on screen (format: "cutscr:max,suffix,string" or "cutscr:+max,suffix,string")
8. a reversed string (format: "rev:xxx" or "revscr:xxx")
9. a repeated string (format: "repeat:count,string")
10. length of a string (format: "length:xxx" or "lengthscr:xxx")
11. split of a string (format: "split:number,separators,flags,xxx")
12. split of shell argmuents (format: "split_shell:number,xxx")
13. a color (format: "color:xxx", see "Plugin API reference", function "color")
14. a modifier (format: "modifier:name,data,string")
15. an info (format: "info:name,arguments", arguments are optional)
16. a base 16/32/64 encoded/decoded string (format: "base_encode:base,xxx" or "base_decode:base,xxx")
17. current date/time (format: "date" or "date:format")
18. an environment variable (format: "env:XXX")
19. a ternary operator (format: "if:condition?value_if_true:value_if_false")
20. result of an expression with parentheses and operators + - * / // % ** (format: "calc:xxx")
21. a random integer number (format: "random:min,max")
22. a translated string (format: "translate:xxx")
23. define a user variable (format: "define:name,value")
24. an option (format: "file.section.option")
25. a local variable in buffer
26. a hdata name/variable (the value is automatically converted to string), by default "window" and "buffer" point to current window/buffer.
Format for hdata can be one of following:
hdata.var1.var2...: start with a hdata (pointer must be known), and ask variables one after one (other hdata can be followed)
hdata[list].var1.var2...: start with a hdata using a list/pointer/pointer name, for example:
${buffer[gui_buffers].full_name}: full name of first buffer in linked list of buffers
${plugin[weechat_plugins].name}: name of first plugin in linked list of plugins
hdata[pointer].var1.var2...: start with a hdata using a pointer, for example:
${buffer[0x1234abcd].full_name}: full name of the buffer with this pointer (can be used in triggers)
${buffer[my_pointer].full_name}: full name of the buffer with this pointer name (can be used in triggers)
For name of hdata and variables, please look at "Plugin API reference", function "weechat_hdata_get".
Beispiele (einfache Zeichenketten):
/eval -n ${raw:${info:version}} ==> ${info:version}
/eval -n ${eval_cond:${window.win_width}>100} ==> 1
/eval -n ${info:version} ==> 0.4.3
/eval -n ${env:HOME} ==> /home/user
/eval -n ${weechat.look.scroll_amount} ==> 3
/eval -n ${sec.data.password} ==> geheim
/eval -n ${window} ==> 0x2549aa0
/eval -n ${window.buffer} ==> 0x2549320
/eval -n ${window.buffer.full_name} ==> core.weechat
/eval -n ${window.buffer.number} ==> 1
/eval -n ${\t} ==> <tab>
/eval -n ${hide:-,${relay.network.password}} ==> --------
/eval -n ${cut:3,+,test} ==> tes+
/eval -n ${cut:+3,+,test} ==> te+
/eval -n ${date:%H:%M:%S} ==> 07:46:40
/eval -n ${if:${info:term_width}>80?big:small} ==> big
/eval -n ${rev:Hello} ==> olleH
/eval -n ${repeat:5,-} ==> -----
/eval -n ${length:test} ==> 4
/eval -n ${split:1,,,abc,def,ghi} ==> abc
/eval -n ${split:-1,,,abc,def,ghi} ==> ghi
/eval -n ${split:count,,,abc,def,ghi} ==> 3
/eval -n ${split:random,,,abc,def,ghi} ==> def
/eval -n ${split_shell:1,"arg 1" arg2} ==> arg 1
/eval -n ${split_shell:-1,"arg 1" arg2} ==> arg2
/eval -n ${split_shell:count,"arg 1" arg2} ==> 2
/eval -n ${split_shell:random,"arg 1" arg2} ==> arg2
/eval -n ${calc:(5+2)*3} ==> 21
/eval -n ${random:0,10} ==> 3
/eval -n ${base_encode:64,test} ==> dGVzdA==
/eval -n ${base_decode:64,dGVzdA==} ==> test
/eval -n ${translate:Plugin} ==> Erweiterung
Examples (simple strings):
/eval -n ${raw:${info:version}} ==> ${info:version}
/eval -n ${eval_cond:${window.win_width}>100} ==> 1
/eval -n ${info:version} ==> 0.4.3
/eval -n ${env:HOME} ==> /home/user
/eval -n ${weechat.look.scroll_amount} ==> 3
/eval -n ${sec.data.password} ==> secret
/eval -n ${window} ==> 0x2549aa0
/eval -n ${window.buffer} ==> 0x2549320
/eval -n ${window.buffer.full_name} ==> core.weechat
/eval -n ${window.buffer.number} ==> 1
/eval -n ${\t} ==> <tab>
/eval -n ${hide:-,${relay.network.password}} ==> --------
/eval -n ${cut:3,+,test} ==> tes+
/eval -n ${cut:+3,+,test} ==> te+
/eval -n ${date:%H:%M:%S} ==> 07:46:40
/eval -n ${if:${info:term_width}>80?big:small} ==> big
/eval -n ${rev:Hello} ==> olleH
/eval -n ${repeat:5,-} ==> -----
/eval -n ${length:test} ==> 4
/eval -n ${split:1,,,abc,def,ghi} ==> abc
/eval -n ${split:-1,,,abc,def,ghi} ==> ghi
/eval -n ${split:count,,,abc,def,ghi} ==> 3
/eval -n ${split:random,,,abc,def,ghi} ==> def
/eval -n ${split_shell:1,"arg 1" arg2} ==> arg 1
/eval -n ${split_shell:-1,"arg 1" arg2} ==> arg2
/eval -n ${split_shell:count,"arg 1" arg2} ==> 2
/eval -n ${split_shell:random,"arg 1" arg2} ==> arg2
/eval -n ${calc:(5+2)*3} ==> 21
/eval -n ${random:0,10} ==> 3
/eval -n ${base_encode:64,test} ==> dGVzdA==
/eval -n ${base_decode:64,dGVzdA==} ==> test
/eval -n ${translate:Plugin} ==> Extension
/eval -n ${define:len,${calc:5+3}}${len}x${len} ==> 8x8
Beispiele (Bedingungen):
/eval -n -c ${window.buffer.number} > 2 ==> 0
/eval -n -c ${window.win_width} > 100 ==> 1
/eval -n -c (8 > 12) || (5 > 2) ==> 1
/eval -n -c (8 > 12) && (5 > 2) ==> 0
/eval -n -c abcd =~ ^ABC ==> 1
/eval -n -c abcd =~ (?-i)^ABC ==> 0
/eval -n -c abcd =~ (?-i)^abc ==> 1
/eval -n -c abcd !~ abc ==> 0
/eval -n -c abcd =* a*d ==> 1
/eval -n -c abcd =- bc ==> 1
Examples (conditions):
/eval -n -c ${window.buffer.number} > 2 ==> 0
/eval -n -c ${window.win_width} > 100 ==> 1
/eval -n -c (8 > 12) || (5 > 2) ==> 1
/eval -n -c (8 > 12) && (5 > 2) ==> 0
/eval -n -c abcd =~ ^ABC ==> 1
/eval -n -c abcd =~ (?-i)^ABC ==> 0
/eval -n -c abcd =~ (?-i)^abc ==> 1
/eval -n -c abcd !~ abc ==> 0
/eval -n -c abcd =* a*d ==> 1
/eval -n -c abcd =- bc ==> 1
----
[[command_weechat_filter]]
+58 -55
View File
@@ -1375,30 +1375,32 @@ To force a string comparison, you can add double quotes around each expression,
Some variables are replaced in expression, using the format ${variable}, variable can be, by order of priority:
1. the string itself without evaluation (format: "raw:xxx")
2. an evaluated sub-string (format: "eval:xxx")
3. an evaluated condition (format: "eval_cond:xxx")
4. a string with escaped chars (format: "esc:xxx" or "\xxx")
5. a string with chars to hide (format: "hide:char,string")
6. a string with max chars (format: "cut:max,suffix,string" or "cut:+max,suffix,string")
2. a user-defined variable (format: "name")
3. an evaluated sub-string (format: "eval:xxx")
4. an evaluated condition (format: "eval_cond:xxx")
5. a string with escaped chars (format: "esc:xxx" or "\xxx")
6. a string with chars to hide (format: "hide:char,string")
7. a string with max chars (format: "cut:max,suffix,string" or "cut:+max,suffix,string")
or max chars displayed on screen (format: "cutscr:max,suffix,string" or "cutscr:+max,suffix,string")
7. a reversed string (format: "rev:xxx" or "revscr:xxx")
8. a repeated string (format: "repeat:count,string")
9. length of a string (format: "length:xxx" or "lengthscr:xxx")
10. split of a string (format: "split:number,separators,flags,xxx")
11. split of shell argmuents (format: "split_shell:number,xxx")
12. a color (format: "color:xxx", see "Plugin API reference", function "color")
13. a modifier (format: "modifier:name,data,string")
14. an info (format: "info:name,arguments", arguments are optional)
15. a base 16/32/64 encoded/decoded string (format: "base_encode:base,xxx" or "base_decode:base,xxx")
16. current date/time (format: "date" or "date:format")
17. an environment variable (format: "env:XXX")
18. a ternary operator (format: "if:condition?value_if_true:value_if_false")
19. result of an expression with parentheses and operators + - * / // % ** (format: "calc:xxx")
20. a random integer number (format: "random:min,max")
21. a translated string (format: "translate:xxx")
22. an option (format: "file.section.option")
23. a local variable in buffer
24. a hdata name/variable (the value is automatically converted to string), by default "window" and "buffer" point to current window/buffer.
8. a reversed string (format: "rev:xxx" or "revscr:xxx")
9. a repeated string (format: "repeat:count,string")
10. length of a string (format: "length:xxx" or "lengthscr:xxx")
11. split of a string (format: "split:number,separators,flags,xxx")
12. split of shell argmuents (format: "split_shell:number,xxx")
13. a color (format: "color:xxx", see "Plugin API reference", function "color")
14. a modifier (format: "modifier:name,data,string")
15. an info (format: "info:name,arguments", arguments are optional)
16. a base 16/32/64 encoded/decoded string (format: "base_encode:base,xxx" or "base_decode:base,xxx")
17. current date/time (format: "date" or "date:format")
18. an environment variable (format: "env:XXX")
19. a ternary operator (format: "if:condition?value_if_true:value_if_false")
20. result of an expression with parentheses and operators + - * / // % ** (format: "calc:xxx")
21. a random integer number (format: "random:min,max")
22. a translated string (format: "translate:xxx")
23. define a user variable (format: "define:name,value")
24. an option (format: "file.section.option")
25. a local variable in buffer
26. a hdata name/variable (the value is automatically converted to string), by default "window" and "buffer" point to current window/buffer.
Format for hdata can be one of following:
hdata.var1.var2...: start with a hdata (pointer must be known), and ask variables one after one (other hdata can be followed)
hdata[list].var1.var2...: start with a hdata using a list/pointer/pointer name, for example:
@@ -1410,38 +1412,39 @@ Format for hdata can be one of following:
For name of hdata and variables, please look at "Plugin API reference", function "weechat_hdata_get".
Examples (simple strings):
/eval -n ${raw:${info:version}} ==> ${info:version}
/eval -n ${eval_cond:${window.win_width}>100} ==> 1
/eval -n ${info:version} ==> 0.4.3
/eval -n ${env:HOME} ==> /home/user
/eval -n ${weechat.look.scroll_amount} ==> 3
/eval -n ${sec.data.password} ==> secret
/eval -n ${window} ==> 0x2549aa0
/eval -n ${window.buffer} ==> 0x2549320
/eval -n ${window.buffer.full_name} ==> core.weechat
/eval -n ${window.buffer.number} ==> 1
/eval -n ${\t} ==> <tab>
/eval -n ${hide:-,${relay.network.password}} ==> --------
/eval -n ${cut:3,+,test} ==> tes+
/eval -n ${cut:+3,+,test} ==> te+
/eval -n ${date:%H:%M:%S} ==> 07:46:40
/eval -n ${if:${info:term_width}>80?big:small} ==> big
/eval -n ${rev:Hello} ==> olleH
/eval -n ${repeat:5,-} ==> -----
/eval -n ${length:test} ==> 4
/eval -n ${split:1,,,abc,def,ghi} ==> abc
/eval -n ${split:-1,,,abc,def,ghi} ==> ghi
/eval -n ${split:count,,,abc,def,ghi} ==> 3
/eval -n ${split:random,,,abc,def,ghi} ==> def
/eval -n ${split_shell:1,"arg 1" arg2} ==> arg 1
/eval -n ${split_shell:-1,"arg 1" arg2} ==> arg2
/eval -n ${split_shell:count,"arg 1" arg2} ==> 2
/eval -n ${split_shell:random,"arg 1" arg2} ==> arg2
/eval -n ${calc:(5+2)*3} ==> 21
/eval -n ${random:0,10} ==> 3
/eval -n ${base_encode:64,test} ==> dGVzdA==
/eval -n ${base_decode:64,dGVzdA==} ==> test
/eval -n ${translate:Plugin} ==> Extension
/eval -n ${raw:${info:version}} ==> ${info:version}
/eval -n ${eval_cond:${window.win_width}>100} ==> 1
/eval -n ${info:version} ==> 0.4.3
/eval -n ${env:HOME} ==> /home/user
/eval -n ${weechat.look.scroll_amount} ==> 3
/eval -n ${sec.data.password} ==> secret
/eval -n ${window} ==> 0x2549aa0
/eval -n ${window.buffer} ==> 0x2549320
/eval -n ${window.buffer.full_name} ==> core.weechat
/eval -n ${window.buffer.number} ==> 1
/eval -n ${\t} ==> <tab>
/eval -n ${hide:-,${relay.network.password}} ==> --------
/eval -n ${cut:3,+,test} ==> tes+
/eval -n ${cut:+3,+,test} ==> te+
/eval -n ${date:%H:%M:%S} ==> 07:46:40
/eval -n ${if:${info:term_width}>80?big:small} ==> big
/eval -n ${rev:Hello} ==> olleH
/eval -n ${repeat:5,-} ==> -----
/eval -n ${length:test} ==> 4
/eval -n ${split:1,,,abc,def,ghi} ==> abc
/eval -n ${split:-1,,,abc,def,ghi} ==> ghi
/eval -n ${split:count,,,abc,def,ghi} ==> 3
/eval -n ${split:random,,,abc,def,ghi} ==> def
/eval -n ${split_shell:1,"arg 1" arg2} ==> arg 1
/eval -n ${split_shell:-1,"arg 1" arg2} ==> arg2
/eval -n ${split_shell:count,"arg 1" arg2} ==> 2
/eval -n ${split_shell:random,"arg 1" arg2} ==> arg2
/eval -n ${calc:(5+2)*3} ==> 21
/eval -n ${random:0,10} ==> 3
/eval -n ${base_encode:64,test} ==> dGVzdA==
/eval -n ${base_decode:64,dGVzdA==} ==> test
/eval -n ${translate:Plugin} ==> Extension
/eval -n ${define:len,${calc:5+3}}${len}x${len} ==> 8x8
Examples (conditions):
/eval -n -c ${window.buffer.number} > 2 ==> 0
+15 -2
View File
@@ -2253,7 +2253,7 @@ str3 = weechat.string_input_for_buffer("//test") # "/test"
==== string_eval_expression
_WeeChat ≥ 0.4.0, updated in 0.4.2, 0.4.3, 1.0, 1.1, 1.2, 1.3, 1.6, 1.8, 2.0,
2.2, 2.3, 2.7, 2.9, 3.1, 3.2 and 3.3._
2.2, 2.3, 2.7, 2.9, 3.1, 3.2, 3.3 and 3.4._
Evaluate an expression and return result as a string.
Special variables with format `+${variable}+` are expanded (see table below).
@@ -2574,6 +2574,12 @@ expanded to last):
`+${raw:${info:version}}+` |
`+${info:version}+`
| `+${name}+` +
_(WeeChat ≥ 3.4)_ |
User variable (defined with `+${define:name,value}+`). |
`+${name}+` |
`+value+`
| `+${name}+` |
Variable `name` from hashtable _extra_vars_. |
`+${name}+` |
@@ -2863,6 +2869,13 @@ expanded to last):
`+${translate:Plugin}+` |
`+Extension+` (example in French)
| `+${define:name,value}+` +
_(WeeChat ≥ 3.4)_ |
Define a variable `name` set to `value`, which can then be used in the same
evaluated expression with `+${name}+`. |
`+${define:len,${calc:5+3}}${len}x${len}+` |
`+8x8+`
| `+${sec.data.name}+` |
Value of the secured data `name`. |
`+${sec.data.libera_pass}+` |
@@ -2880,7 +2893,7 @@ expanded to last):
| `+${pointer}+` |
Variable `pointer` from hashtable _pointers_. |
`+${my_pointer}+` |
`+${buffer}+` |
`+0x1234abcd+`
| `+${hdata.var1.var2...}+` +
+58 -55
View File
@@ -1375,30 +1375,32 @@ Pour forcer une comparaison de chaînes, vous pouvez ajouter des guillemets auto
Des variables sont remplacées dans l'expression, en utilisant le format ${variable}, la variable pouvant être, par ordre de priorité :
1. la chaîne elle-même sans évaluation (format : "raw:xxx")
2. une sous-chaîne évaluée (format : "eval:xxx")
3. une condition évaluée (format : "eval_cond:xxx")
4. une chaîne avec les caractères échappés (format : "esc:xxx" ou "\xxx")
5. une chaîne avec des caractères à cacher (format : "hide:caractère,chaîne")
6. une chaîne avec un maximum de caractères (format : "cut:max,suffixe,chaîne" ou "cut:+max,suffixe,chaîne")
2. une variable définie par l'utilisateur (format : "nom")
3. une sous-chaîne évaluée (format : "eval:xxx")
4. une condition évaluée (format : "eval_cond:xxx")
5. une chaîne avec les caractères échappés (format : "esc:xxx" ou "\xxx")
6. une chaîne avec des caractères à cacher (format : "hide:caractère,chaîne")
7. une chaîne avec un maximum de caractères (format : "cut:max,suffixe,chaîne" ou "cut:+max,suffixe,chaîne")
ou un maximum de caractères affichés à l'écran (format : "cutscr:max,suffixe,chaîne" ou "cutscr:+max,suffixe,chaîne")
7. une chaîne inversée (format : "rev:xxx" ou "revscr:xxx")
8. une chaîne répétée (format : "repeat:nombre,chaîne")
9. longueur d'une chaîne (format : "length:xxx" ou "lengthscr:xxx")
10. découpage d'une chaîne (format : "split:nombre,séparateurs,flags,xxx")
11. découpage de paramètres shell (format : "split_shell:nombre,xxx")
12. une couleur (format : "color:xxx", voir la "Référence API extension", fonction "color")
13. un modificateur (format : "modifier:nom,données,chaîne")
14. une info (format : "info:nom,paramètres", les paramètres sont optionnels)
15. une chaîne encodée/decodée en base 16, 32 ou 64 (format : "base_encode:base,xxx" ou "base_decode:base,xxx")
16. la date/heure courante (format : "date" ou "date:format")
17. une variable d'environnement (format : "env:XXX")
18. un opérateur ternaire (format : "if:condition?valeur_si_vrai:valeur_si_faux")
19. le résultat d'une expression avec parenthèses et les opérateurs + - * / // % ** (format: "calc:xxx")
20. un nombre entier aléatoire (format : "random:min,max")
21. une chaîne traduite (format : "translate:xxx")
22. une option (format : "fichier.section.option")
23. une variable locale du tampon
24. un hdata/variable (la valeur est automatiquement convertie en chaîne), par défaut "window" et "buffer" pointent vers la fenêtre et le tampon courants.
8. une chaîne inversée (format : "rev:xxx" ou "revscr:xxx")
9. une chaîne répétée (format : "repeat:nombre,chaîne")
10. longueur d'une chaîne (format : "length:xxx" ou "lengthscr:xxx")
11. découpage d'une chaîne (format : "split:nombre,séparateurs,flags,xxx")
12. découpage de paramètres shell (format : "split_shell:nombre,xxx")
13. une couleur (format : "color:xxx", voir la "Référence API extension", fonction "color")
14. un modificateur (format : "modifier:nom,données,chaîne")
15. une info (format : "info:nom,paramètres", les paramètres sont optionnels)
16. une chaîne encodée/decodée en base 16, 32 ou 64 (format : "base_encode:base,xxx" ou "base_decode:base,xxx")
17. la date/heure courante (format : "date" ou "date:format")
18. une variable d'environnement (format : "env:XXX")
19. un opérateur ternaire (format : "if:condition?valeur_si_vrai:valeur_si_faux")
20. le résultat d'une expression avec parenthèses et les opérateurs + - * / // % ** (format : "calc:xxx")
21. un nombre entier aléatoire (format : "random:min,max")
22. une chaîne traduite (format : "translate:xxx")
23. déclaration d'une variable utilisateur (format : "define:nom,valeur")
24. une option (format : "fichier.section.option")
25. une variable locale du tampon
26. un hdata/variable (la valeur est automatiquement convertie en chaîne), par défaut "window" et "buffer" pointent vers la fenêtre et le tampon courants.
Le format du hdata peut être le suivant :
hdata.var1.var2... : démarrer avec un hdata (le pointeur doit être connu), et demander les variables l'une après l'autre (d'autres hdata peuvent être suivis)
hdata[liste].var1.var2... : démarrer avec un hdata en utilisant une liste/pointeur/nom de pointeur, par exemple :
@@ -1410,38 +1412,39 @@ Le format du hdata peut être le suivant :
Pour le nom du hdata et des variables, voir la "Référence API extension", fonction "weechat_hdata_get".
Exemples (chaînes simples) :
/eval -n ${raw:${info:version}} ==> ${info:version}
/eval -n ${eval_cond:${window.win_width}>100} ==> 1
/eval -n ${info:version} ==> 0.4.3
/eval -n ${env:HOME} ==> /home/user
/eval -n ${weechat.look.scroll_amount} ==> 3
/eval -n ${sec.data.password} ==> secret
/eval -n ${window} ==> 0x2549aa0
/eval -n ${window.buffer} ==> 0x2549320
/eval -n ${window.buffer.full_name} ==> core.weechat
/eval -n ${window.buffer.number} ==> 1
/eval -n ${\t} ==> <tab>
/eval -n ${hide:-,${relay.network.password}} ==> --------
/eval -n ${cut:3,+,test} ==> tes+
/eval -n ${cut:+3,+,test} ==> te+
/eval -n ${date:%H:%M:%S} ==> 07:46:40
/eval -n ${if:${info:term_width}>80?big:small} ==> big
/eval -n ${rev:Hello} ==> olleH
/eval -n ${repeat:5,-} ==> -----
/eval -n ${length:test} ==> 4
/eval -n ${split:1,,,abc,def,ghi} ==> abc
/eval -n ${split:-1,,,abc,def,ghi} ==> ghi
/eval -n ${split:count,,,abc,def,ghi} ==> 3
/eval -n ${split:random,,,abc,def,ghi} ==> def
/eval -n ${split_shell:1,"arg 1" arg2} ==> arg 1
/eval -n ${split_shell:-1,"arg 1" arg2} ==> arg2
/eval -n ${split_shell:count,"arg 1" arg2} ==> 2
/eval -n ${split_shell:random,"arg 1" arg2} ==> arg2
/eval -n ${calc:(5+2)*3} ==> 21
/eval -n ${random:0,10} ==> 3
/eval -n ${base_encode:64,test} ==> dGVzdA==
/eval -n ${base_decode:64,dGVzdA==} ==> test
/eval -n ${translate:Plugin} ==> Extension
/eval -n ${raw:${info:version}} ==> ${info:version}
/eval -n ${eval_cond:${window.win_width}>100} ==> 1
/eval -n ${info:version} ==> 0.4.3
/eval -n ${env:HOME} ==> /home/user
/eval -n ${weechat.look.scroll_amount} ==> 3
/eval -n ${sec.data.password} ==> secret
/eval -n ${window} ==> 0x2549aa0
/eval -n ${window.buffer} ==> 0x2549320
/eval -n ${window.buffer.full_name} ==> core.weechat
/eval -n ${window.buffer.number} ==> 1
/eval -n ${\t} ==> <tab>
/eval -n ${hide:-,${relay.network.password}} ==> --------
/eval -n ${cut:3,+,test} ==> tes+
/eval -n ${cut:+3,+,test} ==> te+
/eval -n ${date:%H:%M:%S} ==> 07:46:40
/eval -n ${if:${info:term_width}>80?big:small} ==> big
/eval -n ${rev:Hello} ==> olleH
/eval -n ${repeat:5,-} ==> -----
/eval -n ${length:test} ==> 4
/eval -n ${split:1,,,abc,def,ghi} ==> abc
/eval -n ${split:-1,,,abc,def,ghi} ==> ghi
/eval -n ${split:count,,,abc,def,ghi} ==> 3
/eval -n ${split:random,,,abc,def,ghi} ==> def
/eval -n ${split_shell:1,"arg 1" arg2} ==> arg 1
/eval -n ${split_shell:-1,"arg 1" arg2} ==> arg2
/eval -n ${split_shell:count,"arg 1" arg2} ==> 2
/eval -n ${split_shell:random,"arg 1" arg2} ==> arg2
/eval -n ${calc:(5+2)*3} ==> 21
/eval -n ${random:0,10} ==> 3
/eval -n ${base_encode:64,test} ==> dGVzdA==
/eval -n ${base_decode:64,dGVzdA==} ==> test
/eval -n ${translate:Plugin} ==> Extension
/eval -n ${define:len,${calc:5+3}}${len}x${len} ==> 8x8
Exemples (conditions) :
/eval -n -c ${window.buffer.number} > 2 ==> 0
+15 -2
View File
@@ -2291,7 +2291,7 @@ str3 = weechat.string_input_for_buffer("//test") # "/test"
==== string_eval_expression
_WeeChat ≥ 0.4.0, mis à jour dans la 0.4.2, 0.4.3, 1.0, 1.1, 1.2, 1.3, 1.6, 1.8,
2.0, 2.2, 2.3, 2.7, 2.9, 3.1, 3.2 et 3.3._
2.0, 2.2, 2.3, 2.7, 2.9, 3.1, 3.2, 3.3 et 3.4._
Évaluer l'expression et retourner le résultat sous forme de chaîne.
Les variables spéciales avec le format `+${variable}+` sont étendues (voir le
@@ -2618,6 +2618,12 @@ première étendue à la dernière) :
`+${raw:${info:version}}+` |
`+${info:version}+`
| `+${nom}+` +
_(WeeChat ≥ 3.4)_ |
Variable définie par l'utilisateur (avec `+${define:nom,valeur}+`). |
`+${nom}+` |
`+valeur+`
| `+${nom}+` |
Variable `nom` de la table de hachage _extra_vars_. |
`+${nom}+` |
@@ -2910,6 +2916,13 @@ première étendue à la dernière) :
`+${translate:Plugin}+` |
`+Extension+` (exemple en Français)
| `+${define:nom,valeur}+` +
_(WeeChat ≥ 3.4)_ |
Définir une variable `nom` à `valeur`, qui peut être utilisée dans la même
expression évaluée avec `+${nom}+`. |
`+${define:len,${calc:5+3}}${len}x${len}+` |
`+8x8+`
| `+${sec.data.nom}+` |
Valeur de la donnée sécurisée `nom`. |
`+${sec.data.libera_pass}+` |
@@ -2927,7 +2940,7 @@ première étendue à la dernière) :
| `+${pointeur}+` |
Variable `pointeur` de la table de hachage _pointers_. |
`+${mon_pointeur}+` |
`+${buffer}+` |
`+0x1234abcd+`
| `+${hdata.var1.var2...}+` +
+58 -55
View File
@@ -1375,30 +1375,32 @@ To force a string comparison, you can add double quotes around each expression,
Some variables are replaced in expression, using the format ${variable}, variable can be, by order of priority:
1. the string itself without evaluation (format: "raw:xxx")
2. an evaluated sub-string (format: "eval:xxx")
3. an evaluated condition (format: "eval_cond:xxx")
4. a string with escaped chars (format: "esc:xxx" or "\xxx")
5. a string with chars to hide (format: "hide:char,string")
6. a string with max chars (format: "cut:max,suffix,string" or "cut:+max,suffix,string")
2. a user-defined variable (format: "name")
3. an evaluated sub-string (format: "eval:xxx")
4. an evaluated condition (format: "eval_cond:xxx")
5. a string with escaped chars (format: "esc:xxx" or "\xxx")
6. a string with chars to hide (format: "hide:char,string")
7. a string with max chars (format: "cut:max,suffix,string" or "cut:+max,suffix,string")
or max chars displayed on screen (format: "cutscr:max,suffix,string" or "cutscr:+max,suffix,string")
7. a reversed string (format: "rev:xxx" or "revscr:xxx")
8. a repeated string (format: "repeat:count,string")
9. length of a string (format: "length:xxx" or "lengthscr:xxx")
10. split of a string (format: "split:number,separators,flags,xxx")
11. split of shell argmuents (format: "split_shell:number,xxx")
12. a color (format: "color:xxx", see "Plugin API reference", function "color")
13. a modifier (format: "modifier:name,data,string")
14. an info (format: "info:name,arguments", arguments are optional)
15. a base 16/32/64 encoded/decoded string (format: "base_encode:base,xxx" or "base_decode:base,xxx")
16. current date/time (format: "date" or "date:format")
17. an environment variable (format: "env:XXX")
18. a ternary operator (format: "if:condition?value_if_true:value_if_false")
19. result of an expression with parentheses and operators + - * / // % ** (format: "calc:xxx")
20. a random integer number (format: "random:min,max")
21. a translated string (format: "translate:xxx")
22. an option (format: "file.section.option")
23. a local variable in buffer
24. a hdata name/variable (the value is automatically converted to string), by default "window" and "buffer" point to current window/buffer.
8. a reversed string (format: "rev:xxx" or "revscr:xxx")
9. a repeated string (format: "repeat:count,string")
10. length of a string (format: "length:xxx" or "lengthscr:xxx")
11. split of a string (format: "split:number,separators,flags,xxx")
12. split of shell argmuents (format: "split_shell:number,xxx")
13. a color (format: "color:xxx", see "Plugin API reference", function "color")
14. a modifier (format: "modifier:name,data,string")
15. an info (format: "info:name,arguments", arguments are optional)
16. a base 16/32/64 encoded/decoded string (format: "base_encode:base,xxx" or "base_decode:base,xxx")
17. current date/time (format: "date" or "date:format")
18. an environment variable (format: "env:XXX")
19. a ternary operator (format: "if:condition?value_if_true:value_if_false")
20. result of an expression with parentheses and operators + - * / // % ** (format: "calc:xxx")
21. a random integer number (format: "random:min,max")
22. a translated string (format: "translate:xxx")
23. define a user variable (format: "define:name,value")
24. an option (format: "file.section.option")
25. a local variable in buffer
26. a hdata name/variable (the value is automatically converted to string), by default "window" and "buffer" point to current window/buffer.
Format for hdata can be one of following:
hdata.var1.var2...: start with a hdata (pointer must be known), and ask variables one after one (other hdata can be followed)
hdata[list].var1.var2...: start with a hdata using a list/pointer/pointer name, for example:
@@ -1410,38 +1412,39 @@ Format for hdata can be one of following:
For name of hdata and variables, please look at "Plugin API reference", function "weechat_hdata_get".
Examples (simple strings):
/eval -n ${raw:${info:version}} ==> ${info:version}
/eval -n ${eval_cond:${window.win_width}>100} ==> 1
/eval -n ${info:version} ==> 0.4.3
/eval -n ${env:HOME} ==> /home/user
/eval -n ${weechat.look.scroll_amount} ==> 3
/eval -n ${sec.data.password} ==> secret
/eval -n ${window} ==> 0x2549aa0
/eval -n ${window.buffer} ==> 0x2549320
/eval -n ${window.buffer.full_name} ==> core.weechat
/eval -n ${window.buffer.number} ==> 1
/eval -n ${\t} ==> <tab>
/eval -n ${hide:-,${relay.network.password}} ==> --------
/eval -n ${cut:3,+,test} ==> tes+
/eval -n ${cut:+3,+,test} ==> te+
/eval -n ${date:%H:%M:%S} ==> 07:46:40
/eval -n ${if:${info:term_width}>80?big:small} ==> big
/eval -n ${rev:Hello} ==> olleH
/eval -n ${repeat:5,-} ==> -----
/eval -n ${length:test} ==> 4
/eval -n ${split:1,,,abc,def,ghi} ==> abc
/eval -n ${split:-1,,,abc,def,ghi} ==> ghi
/eval -n ${split:count,,,abc,def,ghi} ==> 3
/eval -n ${split:random,,,abc,def,ghi} ==> def
/eval -n ${split_shell:1,"arg 1" arg2} ==> arg 1
/eval -n ${split_shell:-1,"arg 1" arg2} ==> arg2
/eval -n ${split_shell:count,"arg 1" arg2} ==> 2
/eval -n ${split_shell:random,"arg 1" arg2} ==> arg2
/eval -n ${calc:(5+2)*3} ==> 21
/eval -n ${random:0,10} ==> 3
/eval -n ${base_encode:64,test} ==> dGVzdA==
/eval -n ${base_decode:64,dGVzdA==} ==> test
/eval -n ${translate:Plugin} ==> Extension
/eval -n ${raw:${info:version}} ==> ${info:version}
/eval -n ${eval_cond:${window.win_width}>100} ==> 1
/eval -n ${info:version} ==> 0.4.3
/eval -n ${env:HOME} ==> /home/user
/eval -n ${weechat.look.scroll_amount} ==> 3
/eval -n ${sec.data.password} ==> secret
/eval -n ${window} ==> 0x2549aa0
/eval -n ${window.buffer} ==> 0x2549320
/eval -n ${window.buffer.full_name} ==> core.weechat
/eval -n ${window.buffer.number} ==> 1
/eval -n ${\t} ==> <tab>
/eval -n ${hide:-,${relay.network.password}} ==> --------
/eval -n ${cut:3,+,test} ==> tes+
/eval -n ${cut:+3,+,test} ==> te+
/eval -n ${date:%H:%M:%S} ==> 07:46:40
/eval -n ${if:${info:term_width}>80?big:small} ==> big
/eval -n ${rev:Hello} ==> olleH
/eval -n ${repeat:5,-} ==> -----
/eval -n ${length:test} ==> 4
/eval -n ${split:1,,,abc,def,ghi} ==> abc
/eval -n ${split:-1,,,abc,def,ghi} ==> ghi
/eval -n ${split:count,,,abc,def,ghi} ==> 3
/eval -n ${split:random,,,abc,def,ghi} ==> def
/eval -n ${split_shell:1,"arg 1" arg2} ==> arg 1
/eval -n ${split_shell:-1,"arg 1" arg2} ==> arg2
/eval -n ${split_shell:count,"arg 1" arg2} ==> 2
/eval -n ${split_shell:random,"arg 1" arg2} ==> arg2
/eval -n ${calc:(5+2)*3} ==> 21
/eval -n ${random:0,10} ==> 3
/eval -n ${base_encode:64,test} ==> dGVzdA==
/eval -n ${base_decode:64,dGVzdA==} ==> test
/eval -n ${translate:Plugin} ==> Extension
/eval -n ${define:len,${calc:5+3}}${len}x${len} ==> 8x8
Examples (conditions):
/eval -n -c ${window.buffer.number} > 2 ==> 0
+15 -2
View File
@@ -2351,7 +2351,7 @@ str3 = weechat.string_input_for_buffer("//test") # "/test"
==== string_eval_expression
_WeeChat ≥ 0.4.0, updated in 0.4.2, 0.4.3, 1.0, 1.1, 1.2, 1.3, 1.6, 1.8, 2.0,
2.2, 2.3, 2.7, 2.9, 3.1, 3.2 and 3.3._
2.2, 2.3, 2.7, 2.9, 3.1, 3.2, 3.3 and 3.4._
Evaluate an expression and return result as a string.
Special variables with format `+${variable}+` are expanded (see table below).
@@ -2672,6 +2672,12 @@ expanded to last):
`+${raw:${info:version}}+` |
`+${info:version}+`
| `+${name}+` +
_(WeeChat ≥ 3.4)_ |
User variable (defined with `+${define:name,value}+`). |
`+${name}+` |
`+value+`
| `+${name}+` |
Variable `name` from hashtable _extra_vars_. |
`+${name}+` |
@@ -2960,6 +2966,13 @@ expanded to last):
`+${translate:Plugin}+` |
`+Extension+` (example in French)
| `+${define:name,value}+` +
_(WeeChat ≥ 3.4)_ |
Define a variable `name` set to `value`, which can then be used in the same
evaluated expression with `+${name}+`. |
`+${define:len,${calc:5+3}}${len}x${len}+` |
`+8x8+`
| `+${sec.data.name}+` |
Value of the secured data `name`. |
`+${sec.data.libera_pass}+` |
@@ -2977,7 +2990,7 @@ expanded to last):
| `+${pointer}+` |
Variable `pointer` from hashtable _pointers_. |
`+${my_pointer}+` |
`+${buffer}+` |
`+0x1234abcd+`
| `+${hdata.var1.var2...}+` +
+58 -55
View File
@@ -1375,30 +1375,32 @@ To force a string comparison, you can add double quotes around each expression,
Some variables are replaced in expression, using the format ${variable}, variable can be, by order of priority:
1. the string itself without evaluation (format: "raw:xxx")
2. an evaluated sub-string (format: "eval:xxx")
3. an evaluated condition (format: "eval_cond:xxx")
4. a string with escaped chars (format: "esc:xxx" or "\xxx")
5. a string with chars to hide (format: "hide:char,string")
6. a string with max chars (format: "cut:max,suffix,string" or "cut:+max,suffix,string")
2. a user-defined variable (format: "name")
3. an evaluated sub-string (format: "eval:xxx")
4. an evaluated condition (format: "eval_cond:xxx")
5. a string with escaped chars (format: "esc:xxx" or "\xxx")
6. a string with chars to hide (format: "hide:char,string")
7. a string with max chars (format: "cut:max,suffix,string" or "cut:+max,suffix,string")
or max chars displayed on screen (format: "cutscr:max,suffix,string" or "cutscr:+max,suffix,string")
7. a reversed string (format: "rev:xxx" or "revscr:xxx")
8. a repeated string (format: "repeat:count,string")
9. length of a string (format: "length:xxx" or "lengthscr:xxx")
10. split of a string (format: "split:number,separators,flags,xxx")
11. split of shell argmuents (format: "split_shell:number,xxx")
12. a color (format: "color:xxx", see "Plugin API reference", function "color")
13. a modifier (format: "modifier:name,data,string")
14. an info (format: "info:name,arguments", arguments are optional)
15. a base 16/32/64 encoded/decoded string (format: "base_encode:base,xxx" or "base_decode:base,xxx")
16. current date/time (format: "date" or "date:format")
17. an environment variable (format: "env:XXX")
18. a ternary operator (format: "if:condition?value_if_true:value_if_false")
19. result of an expression with parentheses and operators + - * / // % ** (format: "calc:xxx")
20. a random integer number (format: "random:min,max")
21. a translated string (format: "translate:xxx")
22. an option (format: "file.section.option")
23. a local variable in buffer
24. a hdata name/variable (the value is automatically converted to string), by default "window" and "buffer" point to current window/buffer.
8. a reversed string (format: "rev:xxx" or "revscr:xxx")
9. a repeated string (format: "repeat:count,string")
10. length of a string (format: "length:xxx" or "lengthscr:xxx")
11. split of a string (format: "split:number,separators,flags,xxx")
12. split of shell argmuents (format: "split_shell:number,xxx")
13. a color (format: "color:xxx", see "Plugin API reference", function "color")
14. a modifier (format: "modifier:name,data,string")
15. an info (format: "info:name,arguments", arguments are optional)
16. a base 16/32/64 encoded/decoded string (format: "base_encode:base,xxx" or "base_decode:base,xxx")
17. current date/time (format: "date" or "date:format")
18. an environment variable (format: "env:XXX")
19. a ternary operator (format: "if:condition?value_if_true:value_if_false")
20. result of an expression with parentheses and operators + - * / // % ** (format: "calc:xxx")
21. a random integer number (format: "random:min,max")
22. a translated string (format: "translate:xxx")
23. define a user variable (format: "define:name,value")
24. an option (format: "file.section.option")
25. a local variable in buffer
26. a hdata name/variable (the value is automatically converted to string), by default "window" and "buffer" point to current window/buffer.
Format for hdata can be one of following:
hdata.var1.var2...: start with a hdata (pointer must be known), and ask variables one after one (other hdata can be followed)
hdata[list].var1.var2...: start with a hdata using a list/pointer/pointer name, for example:
@@ -1410,38 +1412,39 @@ Format for hdata can be one of following:
For name of hdata and variables, please look at "Plugin API reference", function "weechat_hdata_get".
Examples (simple strings):
/eval -n ${raw:${info:version}} ==> ${info:version}
/eval -n ${eval_cond:${window.win_width}>100} ==> 1
/eval -n ${info:version} ==> 0.4.3
/eval -n ${env:HOME} ==> /home/user
/eval -n ${weechat.look.scroll_amount} ==> 3
/eval -n ${sec.data.password} ==> secret
/eval -n ${window} ==> 0x2549aa0
/eval -n ${window.buffer} ==> 0x2549320
/eval -n ${window.buffer.full_name} ==> core.weechat
/eval -n ${window.buffer.number} ==> 1
/eval -n ${\t} ==> <tab>
/eval -n ${hide:-,${relay.network.password}} ==> --------
/eval -n ${cut:3,+,test} ==> tes+
/eval -n ${cut:+3,+,test} ==> te+
/eval -n ${date:%H:%M:%S} ==> 07:46:40
/eval -n ${if:${info:term_width}>80?big:small} ==> big
/eval -n ${rev:Hello} ==> olleH
/eval -n ${repeat:5,-} ==> -----
/eval -n ${length:test} ==> 4
/eval -n ${split:1,,,abc,def,ghi} ==> abc
/eval -n ${split:-1,,,abc,def,ghi} ==> ghi
/eval -n ${split:count,,,abc,def,ghi} ==> 3
/eval -n ${split:random,,,abc,def,ghi} ==> def
/eval -n ${split_shell:1,"arg 1" arg2} ==> arg 1
/eval -n ${split_shell:-1,"arg 1" arg2} ==> arg2
/eval -n ${split_shell:count,"arg 1" arg2} ==> 2
/eval -n ${split_shell:random,"arg 1" arg2} ==> arg2
/eval -n ${calc:(5+2)*3} ==> 21
/eval -n ${random:0,10} ==> 3
/eval -n ${base_encode:64,test} ==> dGVzdA==
/eval -n ${base_decode:64,dGVzdA==} ==> test
/eval -n ${translate:Plugin} ==> Extension
/eval -n ${raw:${info:version}} ==> ${info:version}
/eval -n ${eval_cond:${window.win_width}>100} ==> 1
/eval -n ${info:version} ==> 0.4.3
/eval -n ${env:HOME} ==> /home/user
/eval -n ${weechat.look.scroll_amount} ==> 3
/eval -n ${sec.data.password} ==> secret
/eval -n ${window} ==> 0x2549aa0
/eval -n ${window.buffer} ==> 0x2549320
/eval -n ${window.buffer.full_name} ==> core.weechat
/eval -n ${window.buffer.number} ==> 1
/eval -n ${\t} ==> <tab>
/eval -n ${hide:-,${relay.network.password}} ==> --------
/eval -n ${cut:3,+,test} ==> tes+
/eval -n ${cut:+3,+,test} ==> te+
/eval -n ${date:%H:%M:%S} ==> 07:46:40
/eval -n ${if:${info:term_width}>80?big:small} ==> big
/eval -n ${rev:Hello} ==> olleH
/eval -n ${repeat:5,-} ==> -----
/eval -n ${length:test} ==> 4
/eval -n ${split:1,,,abc,def,ghi} ==> abc
/eval -n ${split:-1,,,abc,def,ghi} ==> ghi
/eval -n ${split:count,,,abc,def,ghi} ==> 3
/eval -n ${split:random,,,abc,def,ghi} ==> def
/eval -n ${split_shell:1,"arg 1" arg2} ==> arg 1
/eval -n ${split_shell:-1,"arg 1" arg2} ==> arg2
/eval -n ${split_shell:count,"arg 1" arg2} ==> 2
/eval -n ${split_shell:random,"arg 1" arg2} ==> arg2
/eval -n ${calc:(5+2)*3} ==> 21
/eval -n ${random:0,10} ==> 3
/eval -n ${base_encode:64,test} ==> dGVzdA==
/eval -n ${base_decode:64,dGVzdA==} ==> test
/eval -n ${translate:Plugin} ==> Extension
/eval -n ${define:len,${calc:5+3}}${len}x${len} ==> 8x8
Examples (conditions):
/eval -n -c ${window.buffer.number} > 2 ==> 0
+17 -2
View File
@@ -2274,7 +2274,7 @@ str3 = weechat.string_input_for_buffer("//test") # "/test"
// TRANSLATION MISSING
_WeeChat ≥ 0.4.0, updated in 0.4.2, 0.4.3, 1.0, 1.1, 1.2, 1.3, 1.6, 1.8, 2.0,
2.2, 2.3, 2.7, 2.9, 3.1, 3.2 and 3.3._
2.2, 2.3, 2.7, 2.9, 3.1, 3.2, 3.3 and 3.4._
式を評価して文字列として返す。`+${variable}+`
という書式で書かれた特殊変数は展開されます (以下の表を参照)。
@@ -2603,6 +2603,13 @@ str5 = weechat.string_eval_expression("password=abc password=def", {}, {}, optio
`+${raw:${info:version}}+` |
`+${info:version}+`
// TRANSLATION MISSING
| `+${name}+` +
_(WeeChat ≥ 3.4)_ |
User variable (defined with `+${define:name,value}+`). |
`+${name}+` |
`+value+`
| `+${name}+` |
_extra_vars_ の変数 `name` の値に展開 |
`+${name}+` |
@@ -2907,6 +2914,14 @@ str5 = weechat.string_eval_expression("password=abc password=def", {}, {}, optio
`+${translate:Plugin}+` |
`+Extension+` (example in French)
// TRANSLATION MISSING
| `+${define:name,value}+` +
_(WeeChat ≥ 3.4)_ |
Define a variable `name` set to `value`, which can then be used in the same
evaluated expression with `+${name}+`. |
`+${define:len,${calc:5+3}}${len}x${len}+` |
`+8x8+`
| `+${sec.data.name}+` |
セキュアデータ `name` の値 |
`+${sec.data.libera_pass}+` |
@@ -2924,7 +2939,7 @@ str5 = weechat.string_eval_expression("password=abc password=def", {}, {}, optio
| `+${pointer}+` |
_pointers_ の変数 `pointer` の値に展開 |
`+${my_pointer}+` |
`+${buffer}+` |
`+0x1234abcd+`
// TRANSLATION MISSING
+58 -55
View File
@@ -1374,30 +1374,32 @@ To force a string comparison, you can add double quotes around each expression,
Some variables are replaced in expression, using the format ${variable}, variable can be, by order of priority:
1. the string itself without evaluation (format: "raw:xxx")
2. an evaluated sub-string (format: "eval:xxx")
3. an evaluated condition (format: "eval_cond:xxx")
4. a string with escaped chars (format: "esc:xxx" or "\xxx")
5. a string with chars to hide (format: "hide:char,string")
6. a string with max chars (format: "cut:max,suffix,string" or "cut:+max,suffix,string")
2. a user-defined variable (format: "name")
3. an evaluated sub-string (format: "eval:xxx")
4. an evaluated condition (format: "eval_cond:xxx")
5. a string with escaped chars (format: "esc:xxx" or "\xxx")
6. a string with chars to hide (format: "hide:char,string")
7. a string with max chars (format: "cut:max,suffix,string" or "cut:+max,suffix,string")
or max chars displayed on screen (format: "cutscr:max,suffix,string" or "cutscr:+max,suffix,string")
7. a reversed string (format: "rev:xxx" or "revscr:xxx")
8. a repeated string (format: "repeat:count,string")
9. length of a string (format: "length:xxx" or "lengthscr:xxx")
10. split of a string (format: "split:number,separators,flags,xxx")
11. split of shell argmuents (format: "split_shell:number,xxx")
12. a color (format: "color:xxx", see "Plugin API reference", function "color")
13. a modifier (format: "modifier:name,data,string")
14. an info (format: "info:name,arguments", arguments are optional)
15. a base 16/32/64 encoded/decoded string (format: "base_encode:base,xxx" or "base_decode:base,xxx")
16. current date/time (format: "date" or "date:format")
17. an environment variable (format: "env:XXX")
18. a ternary operator (format: "if:condition?value_if_true:value_if_false")
19. result of an expression with parentheses and operators + - * / // % ** (format: "calc:xxx")
20. a random integer number (format: "random:min,max")
21. a translated string (format: "translate:xxx")
22. an option (format: "file.section.option")
23. a local variable in buffer
24. a hdata name/variable (the value is automatically converted to string), by default "window" and "buffer" point to current window/buffer.
8. a reversed string (format: "rev:xxx" or "revscr:xxx")
9. a repeated string (format: "repeat:count,string")
10. length of a string (format: "length:xxx" or "lengthscr:xxx")
11. split of a string (format: "split:number,separators,flags,xxx")
12. split of shell argmuents (format: "split_shell:number,xxx")
13. a color (format: "color:xxx", see "Plugin API reference", function "color")
14. a modifier (format: "modifier:name,data,string")
15. an info (format: "info:name,arguments", arguments are optional)
16. a base 16/32/64 encoded/decoded string (format: "base_encode:base,xxx" or "base_decode:base,xxx")
17. current date/time (format: "date" or "date:format")
18. an environment variable (format: "env:XXX")
19. a ternary operator (format: "if:condition?value_if_true:value_if_false")
20. result of an expression with parentheses and operators + - * / // % ** (format: "calc:xxx")
21. a random integer number (format: "random:min,max")
22. a translated string (format: "translate:xxx")
23. define a user variable (format: "define:name,value")
24. an option (format: "file.section.option")
25. a local variable in buffer
26. a hdata name/variable (the value is automatically converted to string), by default "window" and "buffer" point to current window/buffer.
Format for hdata can be one of following:
hdata.var1.var2...: start with a hdata (pointer must be known), and ask variables one after one (other hdata can be followed)
hdata[list].var1.var2...: start with a hdata using a list/pointer/pointer name, for example:
@@ -1409,38 +1411,39 @@ Format for hdata can be one of following:
For name of hdata and variables, please look at "Plugin API reference", function "weechat_hdata_get".
Examples (simple strings):
/eval -n ${raw:${info:version}} ==> ${info:version}
/eval -n ${eval_cond:${window.win_width}>100} ==> 1
/eval -n ${info:version} ==> 0.4.3
/eval -n ${env:HOME} ==> /home/user
/eval -n ${weechat.look.scroll_amount} ==> 3
/eval -n ${sec.data.password} ==> secret
/eval -n ${window} ==> 0x2549aa0
/eval -n ${window.buffer} ==> 0x2549320
/eval -n ${window.buffer.full_name} ==> core.weechat
/eval -n ${window.buffer.number} ==> 1
/eval -n ${\t} ==> <tab>
/eval -n ${hide:-,${relay.network.password}} ==> --------
/eval -n ${cut:3,+,test} ==> tes+
/eval -n ${cut:+3,+,test} ==> te+
/eval -n ${date:%H:%M:%S} ==> 07:46:40
/eval -n ${if:${info:term_width}>80?big:small} ==> big
/eval -n ${rev:Hello} ==> olleH
/eval -n ${repeat:5,-} ==> -----
/eval -n ${length:test} ==> 4
/eval -n ${split:1,,,abc,def,ghi} ==> abc
/eval -n ${split:-1,,,abc,def,ghi} ==> ghi
/eval -n ${split:count,,,abc,def,ghi} ==> 3
/eval -n ${split:random,,,abc,def,ghi} ==> def
/eval -n ${split_shell:1,"arg 1" arg2} ==> arg 1
/eval -n ${split_shell:-1,"arg 1" arg2} ==> arg2
/eval -n ${split_shell:count,"arg 1" arg2} ==> 2
/eval -n ${split_shell:random,"arg 1" arg2} ==> arg2
/eval -n ${calc:(5+2)*3} ==> 21
/eval -n ${random:0,10} ==> 3
/eval -n ${base_encode:64,test} ==> dGVzdA==
/eval -n ${base_decode:64,dGVzdA==} ==> test
/eval -n ${translate:Plugin} ==> Extension
/eval -n ${raw:${info:version}} ==> ${info:version}
/eval -n ${eval_cond:${window.win_width}>100} ==> 1
/eval -n ${info:version} ==> 0.4.3
/eval -n ${env:HOME} ==> /home/user
/eval -n ${weechat.look.scroll_amount} ==> 3
/eval -n ${sec.data.password} ==> secret
/eval -n ${window} ==> 0x2549aa0
/eval -n ${window.buffer} ==> 0x2549320
/eval -n ${window.buffer.full_name} ==> core.weechat
/eval -n ${window.buffer.number} ==> 1
/eval -n ${\t} ==> <tab>
/eval -n ${hide:-,${relay.network.password}} ==> --------
/eval -n ${cut:3,+,test} ==> tes+
/eval -n ${cut:+3,+,test} ==> te+
/eval -n ${date:%H:%M:%S} ==> 07:46:40
/eval -n ${if:${info:term_width}>80?big:small} ==> big
/eval -n ${rev:Hello} ==> olleH
/eval -n ${repeat:5,-} ==> -----
/eval -n ${length:test} ==> 4
/eval -n ${split:1,,,abc,def,ghi} ==> abc
/eval -n ${split:-1,,,abc,def,ghi} ==> ghi
/eval -n ${split:count,,,abc,def,ghi} ==> 3
/eval -n ${split:random,,,abc,def,ghi} ==> def
/eval -n ${split_shell:1,"arg 1" arg2} ==> arg 1
/eval -n ${split_shell:-1,"arg 1" arg2} ==> arg2
/eval -n ${split_shell:count,"arg 1" arg2} ==> 2
/eval -n ${split_shell:random,"arg 1" arg2} ==> arg2
/eval -n ${calc:(5+2)*3} ==> 21
/eval -n ${random:0,10} ==> 3
/eval -n ${base_encode:64,test} ==> dGVzdA==
/eval -n ${base_decode:64,dGVzdA==} ==> test
/eval -n ${translate:Plugin} ==> Extension
/eval -n ${define:len,${calc:5+3}}${len}x${len} ==> 8x8
Examples (conditions):
/eval -n -c ${window.buffer.number} > 2 ==> 0
+58 -55
View File
@@ -1375,30 +1375,32 @@ To force a string comparison, you can add double quotes around each expression,
Some variables are replaced in expression, using the format ${variable}, variable can be, by order of priority:
1. the string itself without evaluation (format: "raw:xxx")
2. an evaluated sub-string (format: "eval:xxx")
3. an evaluated condition (format: "eval_cond:xxx")
4. a string with escaped chars (format: "esc:xxx" or "\xxx")
5. a string with chars to hide (format: "hide:char,string")
6. a string with max chars (format: "cut:max,suffix,string" or "cut:+max,suffix,string")
2. a user-defined variable (format: "name")
3. an evaluated sub-string (format: "eval:xxx")
4. an evaluated condition (format: "eval_cond:xxx")
5. a string with escaped chars (format: "esc:xxx" or "\xxx")
6. a string with chars to hide (format: "hide:char,string")
7. a string with max chars (format: "cut:max,suffix,string" or "cut:+max,suffix,string")
or max chars displayed on screen (format: "cutscr:max,suffix,string" or "cutscr:+max,suffix,string")
7. a reversed string (format: "rev:xxx" or "revscr:xxx")
8. a repeated string (format: "repeat:count,string")
9. length of a string (format: "length:xxx" or "lengthscr:xxx")
10. split of a string (format: "split:number,separators,flags,xxx")
11. split of shell argmuents (format: "split_shell:number,xxx")
12. a color (format: "color:xxx", see "Plugin API reference", function "color")
13. a modifier (format: "modifier:name,data,string")
14. an info (format: "info:name,arguments", arguments are optional)
15. a base 16/32/64 encoded/decoded string (format: "base_encode:base,xxx" or "base_decode:base,xxx")
16. current date/time (format: "date" or "date:format")
17. an environment variable (format: "env:XXX")
18. a ternary operator (format: "if:condition?value_if_true:value_if_false")
19. result of an expression with parentheses and operators + - * / // % ** (format: "calc:xxx")
20. a random integer number (format: "random:min,max")
21. a translated string (format: "translate:xxx")
22. an option (format: "file.section.option")
23. a local variable in buffer
24. a hdata name/variable (the value is automatically converted to string), by default "window" and "buffer" point to current window/buffer.
8. a reversed string (format: "rev:xxx" or "revscr:xxx")
9. a repeated string (format: "repeat:count,string")
10. length of a string (format: "length:xxx" or "lengthscr:xxx")
11. split of a string (format: "split:number,separators,flags,xxx")
12. split of shell argmuents (format: "split_shell:number,xxx")
13. a color (format: "color:xxx", see "Plugin API reference", function "color")
14. a modifier (format: "modifier:name,data,string")
15. an info (format: "info:name,arguments", arguments are optional)
16. a base 16/32/64 encoded/decoded string (format: "base_encode:base,xxx" or "base_decode:base,xxx")
17. current date/time (format: "date" or "date:format")
18. an environment variable (format: "env:XXX")
19. a ternary operator (format: "if:condition?value_if_true:value_if_false")
20. result of an expression with parentheses and operators + - * / // % ** (format: "calc:xxx")
21. a random integer number (format: "random:min,max")
22. a translated string (format: "translate:xxx")
23. define a user variable (format: "define:name,value")
24. an option (format: "file.section.option")
25. a local variable in buffer
26. a hdata name/variable (the value is automatically converted to string), by default "window" and "buffer" point to current window/buffer.
Format for hdata can be one of following:
hdata.var1.var2...: start with a hdata (pointer must be known), and ask variables one after one (other hdata can be followed)
hdata[list].var1.var2...: start with a hdata using a list/pointer/pointer name, for example:
@@ -1410,38 +1412,39 @@ Format for hdata can be one of following:
For name of hdata and variables, please look at "Plugin API reference", function "weechat_hdata_get".
Examples (simple strings):
/eval -n ${raw:${info:version}} ==> ${info:version}
/eval -n ${eval_cond:${window.win_width}>100} ==> 1
/eval -n ${info:version} ==> 0.4.3
/eval -n ${env:HOME} ==> /home/user
/eval -n ${weechat.look.scroll_amount} ==> 3
/eval -n ${sec.data.password} ==> secret
/eval -n ${window} ==> 0x2549aa0
/eval -n ${window.buffer} ==> 0x2549320
/eval -n ${window.buffer.full_name} ==> core.weechat
/eval -n ${window.buffer.number} ==> 1
/eval -n ${\t} ==> <tab>
/eval -n ${hide:-,${relay.network.password}} ==> --------
/eval -n ${cut:3,+,test} ==> tes+
/eval -n ${cut:+3,+,test} ==> te+
/eval -n ${date:%H:%M:%S} ==> 07:46:40
/eval -n ${if:${info:term_width}>80?big:small} ==> big
/eval -n ${rev:Hello} ==> olleH
/eval -n ${repeat:5,-} ==> -----
/eval -n ${length:test} ==> 4
/eval -n ${split:1,,,abc,def,ghi} ==> abc
/eval -n ${split:-1,,,abc,def,ghi} ==> ghi
/eval -n ${split:count,,,abc,def,ghi} ==> 3
/eval -n ${split:random,,,abc,def,ghi} ==> def
/eval -n ${split_shell:1,"arg 1" arg2} ==> arg 1
/eval -n ${split_shell:-1,"arg 1" arg2} ==> arg2
/eval -n ${split_shell:count,"arg 1" arg2} ==> 2
/eval -n ${split_shell:random,"arg 1" arg2} ==> arg2
/eval -n ${calc:(5+2)*3} ==> 21
/eval -n ${random:0,10} ==> 3
/eval -n ${base_encode:64,test} ==> dGVzdA==
/eval -n ${base_decode:64,dGVzdA==} ==> test
/eval -n ${translate:Plugin} ==> Extension
/eval -n ${raw:${info:version}} ==> ${info:version}
/eval -n ${eval_cond:${window.win_width}>100} ==> 1
/eval -n ${info:version} ==> 0.4.3
/eval -n ${env:HOME} ==> /home/user
/eval -n ${weechat.look.scroll_amount} ==> 3
/eval -n ${sec.data.password} ==> secret
/eval -n ${window} ==> 0x2549aa0
/eval -n ${window.buffer} ==> 0x2549320
/eval -n ${window.buffer.full_name} ==> core.weechat
/eval -n ${window.buffer.number} ==> 1
/eval -n ${\t} ==> <tab>
/eval -n ${hide:-,${relay.network.password}} ==> --------
/eval -n ${cut:3,+,test} ==> tes+
/eval -n ${cut:+3,+,test} ==> te+
/eval -n ${date:%H:%M:%S} ==> 07:46:40
/eval -n ${if:${info:term_width}>80?big:small} ==> big
/eval -n ${rev:Hello} ==> olleH
/eval -n ${repeat:5,-} ==> -----
/eval -n ${length:test} ==> 4
/eval -n ${split:1,,,abc,def,ghi} ==> abc
/eval -n ${split:-1,,,abc,def,ghi} ==> ghi
/eval -n ${split:count,,,abc,def,ghi} ==> 3
/eval -n ${split:random,,,abc,def,ghi} ==> def
/eval -n ${split_shell:1,"arg 1" arg2} ==> arg 1
/eval -n ${split_shell:-1,"arg 1" arg2} ==> arg2
/eval -n ${split_shell:count,"arg 1" arg2} ==> 2
/eval -n ${split_shell:random,"arg 1" arg2} ==> arg2
/eval -n ${calc:(5+2)*3} ==> 21
/eval -n ${random:0,10} ==> 3
/eval -n ${base_encode:64,test} ==> dGVzdA==
/eval -n ${base_decode:64,dGVzdA==} ==> test
/eval -n ${translate:Plugin} ==> Extension
/eval -n ${define:len,${calc:5+3}}${len}x${len} ==> 8x8
Examples (conditions):
/eval -n -c ${window.buffer.number} > 2 ==> 0
+17 -2
View File
@@ -2159,7 +2159,7 @@ str3 = weechat.string_input_for_buffer("//test") # "/test"
==== string_eval_expression
_WeeChat ≥ 0.4.0, ажурирано у верзијама 0.4.2, 0.4.3, 1.0, 1.1, 1.2, 1.3, 1.6, 1.8, 2.0, 2.2, 2.3, 2.7, 2.9, 3.1, 3.2 и 3.3._
_WeeChat ≥ 0.4.0, ажурирано у верзијама 0.4.2, 0.4.3, 1.0, 1.1, 1.2, 1.3, 1.6, 1.8, 2.0, 2.2, 2.3, 2.7, 2.9, 3.1, 3.2, 3.3 и 3.4._
Израчунава израз и враћа вредност као стринг. Специјалне променљиве у формату `+${променљива}+` се развијају (погледајте табелу испод).
@@ -2457,6 +2457,13 @@ str5 = weechat.string_eval_expression("password=abc password=def", {}, {}, optio
`+${raw:${info:version}}+` |
`+${info:version}+`
// TRANSLATION MISSING
| `+${name}+` +
_(WeeChat ≥ 3.4)_ |
User variable (defined with `+${define:name,value}+`). |
`+${name}+` |
`+value+`
| `+${име}+` |
Променљива `name` из хеш табеле _extra_vars_. |
`+${име}+` |
@@ -2748,6 +2755,14 @@ str5 = weechat.string_eval_expression("password=abc password=def", {}, {}, optio
`+${translate:Plugin}+` |
`+Extension+` (пример из француског)
// TRANSLATION MISSING
| `+${define:name,value}+` +
_(WeeChat ≥ 3.4)_ |
Define a variable `name` set to `value`, which can then be used in the same
evaluated expression with `+${name}+`. |
`+${define:len,${calc:5+3}}${len}x${len}+` |
`+8x8+`
| `+${sec.data.име}+` |
Вредност обезбеђених података `име`. |
`+${sec.data.libera_pass}+` |
@@ -2765,7 +2780,7 @@ str5 = weechat.string_eval_expression("password=abc password=def", {}, {}, optio
| `+${pointer}+` |
Променљива `pointer` из хеш табеле _pointers_. |
`+${my_pointer}+` |
`+${buffer}+` |
`+0x1234abcd+`
| `+${hdata.пром1.пром2...}+` +
+59 -56
View File
@@ -21,7 +21,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2021-09-09 21:07+0200\n"
"POT-Creation-Date: 2021-09-20 21:12+0200\n"
"PO-Revision-Date: 2021-07-10 16:01+0200\n"
"Last-Translator: Ondřej Súkup <mimi.vx@gmail.com>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@@ -1599,36 +1599,38 @@ msgid ""
"Some variables are replaced in expression, using the format ${variable}, "
"variable can be, by order of priority:\n"
" 1. the string itself without evaluation (format: \"raw:xxx\")\n"
" 2. an evaluated sub-string (format: \"eval:xxx\")\n"
" 3. an evaluated condition (format: \"eval_cond:xxx\")\n"
" 4. a string with escaped chars (format: \"esc:xxx\" or \"\\xxx\")\n"
" 5. a string with chars to hide (format: \"hide:char,string\")\n"
" 6. a string with max chars (format: \"cut:max,suffix,string\" or \"cut:"
" 2. a user-defined variable (format: \"name\")\n"
" 3. an evaluated sub-string (format: \"eval:xxx\")\n"
" 4. an evaluated condition (format: \"eval_cond:xxx\")\n"
" 5. a string with escaped chars (format: \"esc:xxx\" or \"\\xxx\")\n"
" 6. a string with chars to hide (format: \"hide:char,string\")\n"
" 7. a string with max chars (format: \"cut:max,suffix,string\" or \"cut:"
"+max,suffix,string\")\n"
" or max chars displayed on screen (format: \"cutscr:max,suffix,string\" "
"or \"cutscr:+max,suffix,string\")\n"
" 7. a reversed string (format: \"rev:xxx\" or \"revscr:xxx\")\n"
" 8. a repeated string (format: \"repeat:count,string\")\n"
" 9. length of a string (format: \"length:xxx\" or \"lengthscr:xxx\")\n"
" 10. split of a string (format: \"split:number,separators,flags,xxx\")\n"
" 11. split of shell argmuents (format: \"split_shell:number,xxx\")\n"
" 12. a color (format: \"color:xxx\", see \"Plugin API reference\", function "
" 8. a reversed string (format: \"rev:xxx\" or \"revscr:xxx\")\n"
" 9. a repeated string (format: \"repeat:count,string\")\n"
" 10. length of a string (format: \"length:xxx\" or \"lengthscr:xxx\")\n"
" 11. split of a string (format: \"split:number,separators,flags,xxx\")\n"
" 12. split of shell argmuents (format: \"split_shell:number,xxx\")\n"
" 13. a color (format: \"color:xxx\", see \"Plugin API reference\", function "
"\"color\")\n"
" 13. a modifier (format: \"modifier:name,data,string\")\n"
" 14. an info (format: \"info:name,arguments\", arguments are optional)\n"
" 15. a base 16/32/64 encoded/decoded string (format: \"base_encode:base,xxx"
" 14. a modifier (format: \"modifier:name,data,string\")\n"
" 15. an info (format: \"info:name,arguments\", arguments are optional)\n"
" 16. a base 16/32/64 encoded/decoded string (format: \"base_encode:base,xxx"
"\" or \"base_decode:base,xxx\")\n"
" 16. current date/time (format: \"date\" or \"date:format\")\n"
" 17. an environment variable (format: \"env:XXX\")\n"
" 18. a ternary operator (format: \"if:condition?value_if_true:value_if_false"
" 17. current date/time (format: \"date\" or \"date:format\")\n"
" 18. an environment variable (format: \"env:XXX\")\n"
" 19. a ternary operator (format: \"if:condition?value_if_true:value_if_false"
"\")\n"
" 19. result of an expression with parentheses and operators + - * / // % ** "
" 20. result of an expression with parentheses and operators + - * / // % ** "
"(format: \"calc:xxx\")\n"
" 20. a random integer number (format: \"random:min,max\")\n"
" 21. a translated string (format: \"translate:xxx\")\n"
" 22. an option (format: \"file.section.option\")\n"
" 23. a local variable in buffer\n"
" 24. a hdata name/variable (the value is automatically converted to "
" 21. a random integer number (format: \"random:min,max\")\n"
" 22. a translated string (format: \"translate:xxx\")\n"
" 23. define a user variable (format: \"define:name,value\")\n"
" 24. an option (format: \"file.section.option\")\n"
" 25. a local variable in buffer\n"
" 26. a hdata name/variable (the value is automatically converted to "
"string), by default \"window\" and \"buffer\" point to current window/"
"buffer.\n"
"Format for hdata can be one of following:\n"
@@ -1650,38 +1652,39 @@ msgid ""
"function \"weechat_hdata_get\".\n"
"\n"
"Examples (simple strings):\n"
" /eval -n ${raw:${info:version}} ==> ${info:version}\n"
" /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
" /eval -n ${info:version} ==> 0.4.3\n"
" /eval -n ${env:HOME} ==> /home/user\n"
" /eval -n ${weechat.look.scroll_amount} ==> 3\n"
" /eval -n ${sec.data.password} ==> secret\n"
" /eval -n ${window} ==> 0x2549aa0\n"
" /eval -n ${window.buffer} ==> 0x2549320\n"
" /eval -n ${window.buffer.full_name} ==> core.weechat\n"
" /eval -n ${window.buffer.number} ==> 1\n"
" /eval -n ${\\t} ==> <tab>\n"
" /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
" /eval -n ${cut:3,+,test} ==> tes+\n"
" /eval -n ${cut:+3,+,test} ==> te+\n"
" /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
" /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
" /eval -n ${rev:Hello} ==> olleH\n"
" /eval -n ${repeat:5,-} ==> -----\n"
" /eval -n ${length:test} ==> 4\n"
" /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
" /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
" /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
" /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
" /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
" /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
" /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${calc:(5+2)*3} ==> 21\n"
" /eval -n ${random:0,10} ==> 3\n"
" /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
" /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
" /eval -n ${translate:Plugin} ==> Extension\n"
" /eval -n ${raw:${info:version}} ==> ${info:version}\n"
" /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
" /eval -n ${info:version} ==> 0.4.3\n"
" /eval -n ${env:HOME} ==> /home/user\n"
" /eval -n ${weechat.look.scroll_amount} ==> 3\n"
" /eval -n ${sec.data.password} ==> secret\n"
" /eval -n ${window} ==> 0x2549aa0\n"
" /eval -n ${window.buffer} ==> 0x2549320\n"
" /eval -n ${window.buffer.full_name} ==> core.weechat\n"
" /eval -n ${window.buffer.number} ==> 1\n"
" /eval -n ${\\t} ==> <tab>\n"
" /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
" /eval -n ${cut:3,+,test} ==> tes+\n"
" /eval -n ${cut:+3,+,test} ==> te+\n"
" /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
" /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
" /eval -n ${rev:Hello} ==> olleH\n"
" /eval -n ${repeat:5,-} ==> -----\n"
" /eval -n ${length:test} ==> 4\n"
" /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
" /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
" /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
" /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
" /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
" /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
" /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${calc:(5+2)*3} ==> 21\n"
" /eval -n ${random:0,10} ==> 3\n"
" /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
" /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
" /eval -n ${translate:Plugin} ==> Extension\n"
" /eval -n ${define:len,${calc:5+3}}${len}x${len} ==> 8x8\n"
"\n"
"Examples (conditions):\n"
" /eval -n -c ${window.buffer.number} > 2 ==> 0\n"
+206 -59
View File
@@ -24,7 +24,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2021-09-09 21:07+0200\n"
"POT-Creation-Date: 2021-09-20 21:12+0200\n"
"PO-Revision-Date: 2021-09-10 09:56+0200\n"
"Last-Translator: Nils Görs <weechatter@arcor.de>\n"
"Language-Team: German <kde-i18n-de@kde.org>\n"
@@ -1689,6 +1689,153 @@ msgstr ""
"[-n|-s] [-d] <expression> || [-n] [-d [-d]] -c <expression1> <operator> "
"<expression2>"
#, fuzzy
#| msgid ""
#| " -n: display result without sending it to buffer (debug mode)\n"
#| " -s: split expression before evaluating it (many commands can be "
#| "separated by semicolons)\n"
#| " -d: display debug output after evaluation (with two -d: more "
#| "verbose debug)\n"
#| " -c: evaluate as condition: use operators and parentheses, return "
#| "a boolean value (\"0\" or \"1\")\n"
#| "expression: expression to evaluate, variables with format ${variable} are "
#| "replaced (see below); many commands can be separated by semicolons\n"
#| " operator: a logical or comparison operator:\n"
#| " - logical operators:\n"
#| " && boolean \"and\"\n"
#| " || boolean \"or\"\n"
#| " - comparison operators:\n"
#| " == equal\n"
#| " != not equal\n"
#| " <= less or equal\n"
#| " < less\n"
#| " >= greater or equal\n"
#| " > greater\n"
#| " =~ is matching POSIX extended regex\n"
#| " !~ is NOT matching POSIX extended regex\n"
#| " ==* is matching mask, case sensitive (wildcard \"*\" is "
#| "allowed)\n"
#| " !!* is NOT matching mask, case sensitive (wildcard \"*\" "
#| "is allowed)\n"
#| " =* is matching mask, case insensitive (wildcard \"*\" "
#| "is allowed)\n"
#| " !* is NOT matching mask, case insensitive (wildcard \"*"
#| "\" is allowed)\n"
#| " ==- is included, case sensitive\n"
#| " !!- is NOT included, case sensitive\n"
#| " =- is included, case insensitive\n"
#| " !- is NOT included, case insensitive\n"
#| "\n"
#| "An expression is considered as \"true\" if it is not NULL, not empty, and "
#| "different from \"0\".\n"
#| "The comparison is made using floating point numbers if the two "
#| "expressions are valid numbers, with one of the following formats:\n"
#| " - integer (examples: 5, -7)\n"
#| " - floating point number (examples: 5.2, -7.5, 2.83e-2)\n"
#| " - hexadecimal number (examples: 0xA3, -0xA3)\n"
#| "To force a string comparison, you can add double quotes around each "
#| "expression, for example:\n"
#| " 50 > 100 ==> 0\n"
#| " \"50\" > \"100\" ==> 1\n"
#| "\n"
#| "Some variables are replaced in expression, using the format ${variable}, "
#| "variable can be, by order of priority:\n"
#| " 1. the string itself without evaluation (format: \"raw:xxx\")\n"
#| " 2. an evaluated sub-string (format: \"eval:xxx\")\n"
#| " 3. an evaluated condition (format: \"eval_cond:xxx\")\n"
#| " 4. a string with escaped chars (format: \"esc:xxx\" or \"\\xxx\")\n"
#| " 5. a string with chars to hide (format: \"hide:char,string\")\n"
#| " 6. a string with max chars (format: \"cut:max,suffix,string\" or \"cut:"
#| "+max,suffix,string\")\n"
#| " or max chars displayed on screen (format: \"cutscr:max,suffix,string"
#| "\" or \"cutscr:+max,suffix,string\")\n"
#| " 7. a reversed string (format: \"rev:xxx\" or \"revscr:xxx\")\n"
#| " 8. a repeated string (format: \"repeat:count,string\")\n"
#| " 9. length of a string (format: \"length:xxx\" or \"lengthscr:xxx\")\n"
#| " 10. split of a string (format: \"split:number,separators,flags,xxx\")\n"
#| " 11. split of shell argmuents (format: \"split_shell:number,xxx\")\n"
#| " 12. a color (format: \"color:xxx\", see \"Plugin API reference\", "
#| "function \"color\")\n"
#| " 13. a modifier (format: \"modifier:name,data,string\")\n"
#| " 14. an info (format: \"info:name,arguments\", arguments are optional)\n"
#| " 15. a base 16/32/64 encoded/decoded string (format: \"base_encode:base,"
#| "xxx\" or \"base_decode:base,xxx\")\n"
#| " 16. current date/time (format: \"date\" or \"date:format\")\n"
#| " 17. an environment variable (format: \"env:XXX\")\n"
#| " 18. a ternary operator (format: \"if:condition?value_if_true:"
#| "value_if_false\")\n"
#| " 19. result of an expression with parentheses and operators + - * / // % "
#| "** (format: \"calc:xxx\")\n"
#| " 20. a random integer number (format: \"random:min,max\")\n"
#| " 21. a translated string (format: \"translate:xxx\")\n"
#| " 22. an option (format: \"file.section.option\")\n"
#| " 23. a local variable in buffer\n"
#| " 24. a hdata name/variable (the value is automatically converted to "
#| "string), by default \"window\" and \"buffer\" point to current window/"
#| "buffer.\n"
#| "Format for hdata can be one of following:\n"
#| " hdata.var1.var2...: start with a hdata (pointer must be known), and ask "
#| "variables one after one (other hdata can be followed)\n"
#| " hdata[list].var1.var2...: start with a hdata using a list/pointer/"
#| "pointer name, for example:\n"
#| " ${buffer[gui_buffers].full_name}: full name of first buffer in linked "
#| "list of buffers\n"
#| " ${plugin[weechat_plugins].name}: name of first plugin in linked list "
#| "of plugins\n"
#| " hdata[pointer].var1.var2...: start with a hdata using a pointer, for "
#| "example:\n"
#| " ${buffer[0x1234abcd].full_name}: full name of the buffer with this "
#| "pointer (can be used in triggers)\n"
#| " ${buffer[my_pointer].full_name}: full name of the buffer with this "
#| "pointer name (can be used in triggers)\n"
#| "For name of hdata and variables, please look at \"Plugin API reference\", "
#| "function \"weechat_hdata_get\".\n"
#| "\n"
#| "Examples (simple strings):\n"
#| " /eval -n ${raw:${info:version}} ==> ${info:version}\n"
#| " /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
#| " /eval -n ${info:version} ==> 0.4.3\n"
#| " /eval -n ${env:HOME} ==> /home/user\n"
#| " /eval -n ${weechat.look.scroll_amount} ==> 3\n"
#| " /eval -n ${sec.data.password} ==> secret\n"
#| " /eval -n ${window} ==> 0x2549aa0\n"
#| " /eval -n ${window.buffer} ==> 0x2549320\n"
#| " /eval -n ${window.buffer.full_name} ==> core.weechat\n"
#| " /eval -n ${window.buffer.number} ==> 1\n"
#| " /eval -n ${\\t} ==> <tab>\n"
#| " /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
#| " /eval -n ${cut:3,+,test} ==> tes+\n"
#| " /eval -n ${cut:+3,+,test} ==> te+\n"
#| " /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
#| " /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
#| " /eval -n ${rev:Hello} ==> olleH\n"
#| " /eval -n ${repeat:5,-} ==> -----\n"
#| " /eval -n ${length:test} ==> 4\n"
#| " /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
#| " /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
#| " /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
#| " /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
#| " /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
#| " /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
#| " /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
#| " /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
#| " /eval -n ${calc:(5+2)*3} ==> 21\n"
#| " /eval -n ${random:0,10} ==> 3\n"
#| " /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
#| " /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
#| " /eval -n ${translate:Plugin} ==> Extension\n"
#| "\n"
#| "Examples (conditions):\n"
#| " /eval -n -c ${window.buffer.number} > 2 ==> 0\n"
#| " /eval -n -c ${window.win_width} > 100 ==> 1\n"
#| " /eval -n -c (8 > 12) || (5 > 2) ==> 1\n"
#| " /eval -n -c (8 > 12) && (5 > 2) ==> 0\n"
#| " /eval -n -c abcd =~ ^ABC ==> 1\n"
#| " /eval -n -c abcd =~ (?-i)^ABC ==> 0\n"
#| " /eval -n -c abcd =~ (?-i)^abc ==> 1\n"
#| " /eval -n -c abcd !~ abc ==> 0\n"
#| " /eval -n -c abcd =* a*d ==> 1\n"
#| " /eval -n -c abcd =- bc ==> 1"
msgid ""
" -n: display result without sending it to buffer (debug mode)\n"
" -s: split expression before evaluating it (many commands can be "
@@ -1740,36 +1887,38 @@ msgid ""
"Some variables are replaced in expression, using the format ${variable}, "
"variable can be, by order of priority:\n"
" 1. the string itself without evaluation (format: \"raw:xxx\")\n"
" 2. an evaluated sub-string (format: \"eval:xxx\")\n"
" 3. an evaluated condition (format: \"eval_cond:xxx\")\n"
" 4. a string with escaped chars (format: \"esc:xxx\" or \"\\xxx\")\n"
" 5. a string with chars to hide (format: \"hide:char,string\")\n"
" 6. a string with max chars (format: \"cut:max,suffix,string\" or \"cut:"
" 2. a user-defined variable (format: \"name\")\n"
" 3. an evaluated sub-string (format: \"eval:xxx\")\n"
" 4. an evaluated condition (format: \"eval_cond:xxx\")\n"
" 5. a string with escaped chars (format: \"esc:xxx\" or \"\\xxx\")\n"
" 6. a string with chars to hide (format: \"hide:char,string\")\n"
" 7. a string with max chars (format: \"cut:max,suffix,string\" or \"cut:"
"+max,suffix,string\")\n"
" or max chars displayed on screen (format: \"cutscr:max,suffix,string\" "
"or \"cutscr:+max,suffix,string\")\n"
" 7. a reversed string (format: \"rev:xxx\" or \"revscr:xxx\")\n"
" 8. a repeated string (format: \"repeat:count,string\")\n"
" 9. length of a string (format: \"length:xxx\" or \"lengthscr:xxx\")\n"
" 10. split of a string (format: \"split:number,separators,flags,xxx\")\n"
" 11. split of shell argmuents (format: \"split_shell:number,xxx\")\n"
" 12. a color (format: \"color:xxx\", see \"Plugin API reference\", function "
" 8. a reversed string (format: \"rev:xxx\" or \"revscr:xxx\")\n"
" 9. a repeated string (format: \"repeat:count,string\")\n"
" 10. length of a string (format: \"length:xxx\" or \"lengthscr:xxx\")\n"
" 11. split of a string (format: \"split:number,separators,flags,xxx\")\n"
" 12. split of shell argmuents (format: \"split_shell:number,xxx\")\n"
" 13. a color (format: \"color:xxx\", see \"Plugin API reference\", function "
"\"color\")\n"
" 13. a modifier (format: \"modifier:name,data,string\")\n"
" 14. an info (format: \"info:name,arguments\", arguments are optional)\n"
" 15. a base 16/32/64 encoded/decoded string (format: \"base_encode:base,xxx"
" 14. a modifier (format: \"modifier:name,data,string\")\n"
" 15. an info (format: \"info:name,arguments\", arguments are optional)\n"
" 16. a base 16/32/64 encoded/decoded string (format: \"base_encode:base,xxx"
"\" or \"base_decode:base,xxx\")\n"
" 16. current date/time (format: \"date\" or \"date:format\")\n"
" 17. an environment variable (format: \"env:XXX\")\n"
" 18. a ternary operator (format: \"if:condition?value_if_true:value_if_false"
" 17. current date/time (format: \"date\" or \"date:format\")\n"
" 18. an environment variable (format: \"env:XXX\")\n"
" 19. a ternary operator (format: \"if:condition?value_if_true:value_if_false"
"\")\n"
" 19. result of an expression with parentheses and operators + - * / // % ** "
" 20. result of an expression with parentheses and operators + - * / // % ** "
"(format: \"calc:xxx\")\n"
" 20. a random integer number (format: \"random:min,max\")\n"
" 21. a translated string (format: \"translate:xxx\")\n"
" 22. an option (format: \"file.section.option\")\n"
" 23. a local variable in buffer\n"
" 24. a hdata name/variable (the value is automatically converted to "
" 21. a random integer number (format: \"random:min,max\")\n"
" 22. a translated string (format: \"translate:xxx\")\n"
" 23. define a user variable (format: \"define:name,value\")\n"
" 24. an option (format: \"file.section.option\")\n"
" 25. a local variable in buffer\n"
" 26. a hdata name/variable (the value is automatically converted to "
"string), by default \"window\" and \"buffer\" point to current window/"
"buffer.\n"
"Format for hdata can be one of following:\n"
@@ -1791,38 +1940,39 @@ msgid ""
"function \"weechat_hdata_get\".\n"
"\n"
"Examples (simple strings):\n"
" /eval -n ${raw:${info:version}} ==> ${info:version}\n"
" /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
" /eval -n ${info:version} ==> 0.4.3\n"
" /eval -n ${env:HOME} ==> /home/user\n"
" /eval -n ${weechat.look.scroll_amount} ==> 3\n"
" /eval -n ${sec.data.password} ==> secret\n"
" /eval -n ${window} ==> 0x2549aa0\n"
" /eval -n ${window.buffer} ==> 0x2549320\n"
" /eval -n ${window.buffer.full_name} ==> core.weechat\n"
" /eval -n ${window.buffer.number} ==> 1\n"
" /eval -n ${\\t} ==> <tab>\n"
" /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
" /eval -n ${cut:3,+,test} ==> tes+\n"
" /eval -n ${cut:+3,+,test} ==> te+\n"
" /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
" /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
" /eval -n ${rev:Hello} ==> olleH\n"
" /eval -n ${repeat:5,-} ==> -----\n"
" /eval -n ${length:test} ==> 4\n"
" /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
" /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
" /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
" /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
" /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
" /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
" /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${calc:(5+2)*3} ==> 21\n"
" /eval -n ${random:0,10} ==> 3\n"
" /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
" /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
" /eval -n ${translate:Plugin} ==> Extension\n"
" /eval -n ${raw:${info:version}} ==> ${info:version}\n"
" /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
" /eval -n ${info:version} ==> 0.4.3\n"
" /eval -n ${env:HOME} ==> /home/user\n"
" /eval -n ${weechat.look.scroll_amount} ==> 3\n"
" /eval -n ${sec.data.password} ==> secret\n"
" /eval -n ${window} ==> 0x2549aa0\n"
" /eval -n ${window.buffer} ==> 0x2549320\n"
" /eval -n ${window.buffer.full_name} ==> core.weechat\n"
" /eval -n ${window.buffer.number} ==> 1\n"
" /eval -n ${\\t} ==> <tab>\n"
" /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
" /eval -n ${cut:3,+,test} ==> tes+\n"
" /eval -n ${cut:+3,+,test} ==> te+\n"
" /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
" /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
" /eval -n ${rev:Hello} ==> olleH\n"
" /eval -n ${repeat:5,-} ==> -----\n"
" /eval -n ${length:test} ==> 4\n"
" /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
" /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
" /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
" /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
" /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
" /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
" /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${calc:(5+2)*3} ==> 21\n"
" /eval -n ${random:0,10} ==> 3\n"
" /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
" /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
" /eval -n ${translate:Plugin} ==> Extension\n"
" /eval -n ${define:len,${calc:5+3}}${len}x${len} ==> 8x8\n"
"\n"
"Examples (conditions):\n"
" /eval -n -c ${window.buffer.number} > 2 ==> 0\n"
@@ -2629,9 +2779,6 @@ msgstr ""
msgid "list/load/unload plugins"
msgstr "Erweiterungen verwalten (auflisten/installieren/beenden)"
#| msgid ""
#| "list|listfull [<name>] || load <filename> [<arguments>] || autoload "
#| "[<arguments>] || reload [<name>|* [<arguments>]] || unload [<name>]"
msgid ""
"list [-o|-ol|-i|-il|<name>] || listfull [<name>] || load <filename> "
"[<arguments>] || autoload [<arguments>] || reload [<name>|* [<arguments>]] "
+59 -56
View File
@@ -22,7 +22,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2021-09-09 21:07+0200\n"
"POT-Creation-Date: 2021-09-20 21:12+0200\n"
"PO-Revision-Date: 2021-07-10 16:01+0200\n"
"Last-Translator: Elián Hanisch <lambdae2@gmail.com>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@@ -1627,36 +1627,38 @@ msgid ""
"Some variables are replaced in expression, using the format ${variable}, "
"variable can be, by order of priority:\n"
" 1. the string itself without evaluation (format: \"raw:xxx\")\n"
" 2. an evaluated sub-string (format: \"eval:xxx\")\n"
" 3. an evaluated condition (format: \"eval_cond:xxx\")\n"
" 4. a string with escaped chars (format: \"esc:xxx\" or \"\\xxx\")\n"
" 5. a string with chars to hide (format: \"hide:char,string\")\n"
" 6. a string with max chars (format: \"cut:max,suffix,string\" or \"cut:"
" 2. a user-defined variable (format: \"name\")\n"
" 3. an evaluated sub-string (format: \"eval:xxx\")\n"
" 4. an evaluated condition (format: \"eval_cond:xxx\")\n"
" 5. a string with escaped chars (format: \"esc:xxx\" or \"\\xxx\")\n"
" 6. a string with chars to hide (format: \"hide:char,string\")\n"
" 7. a string with max chars (format: \"cut:max,suffix,string\" or \"cut:"
"+max,suffix,string\")\n"
" or max chars displayed on screen (format: \"cutscr:max,suffix,string\" "
"or \"cutscr:+max,suffix,string\")\n"
" 7. a reversed string (format: \"rev:xxx\" or \"revscr:xxx\")\n"
" 8. a repeated string (format: \"repeat:count,string\")\n"
" 9. length of a string (format: \"length:xxx\" or \"lengthscr:xxx\")\n"
" 10. split of a string (format: \"split:number,separators,flags,xxx\")\n"
" 11. split of shell argmuents (format: \"split_shell:number,xxx\")\n"
" 12. a color (format: \"color:xxx\", see \"Plugin API reference\", function "
" 8. a reversed string (format: \"rev:xxx\" or \"revscr:xxx\")\n"
" 9. a repeated string (format: \"repeat:count,string\")\n"
" 10. length of a string (format: \"length:xxx\" or \"lengthscr:xxx\")\n"
" 11. split of a string (format: \"split:number,separators,flags,xxx\")\n"
" 12. split of shell argmuents (format: \"split_shell:number,xxx\")\n"
" 13. a color (format: \"color:xxx\", see \"Plugin API reference\", function "
"\"color\")\n"
" 13. a modifier (format: \"modifier:name,data,string\")\n"
" 14. an info (format: \"info:name,arguments\", arguments are optional)\n"
" 15. a base 16/32/64 encoded/decoded string (format: \"base_encode:base,xxx"
" 14. a modifier (format: \"modifier:name,data,string\")\n"
" 15. an info (format: \"info:name,arguments\", arguments are optional)\n"
" 16. a base 16/32/64 encoded/decoded string (format: \"base_encode:base,xxx"
"\" or \"base_decode:base,xxx\")\n"
" 16. current date/time (format: \"date\" or \"date:format\")\n"
" 17. an environment variable (format: \"env:XXX\")\n"
" 18. a ternary operator (format: \"if:condition?value_if_true:value_if_false"
" 17. current date/time (format: \"date\" or \"date:format\")\n"
" 18. an environment variable (format: \"env:XXX\")\n"
" 19. a ternary operator (format: \"if:condition?value_if_true:value_if_false"
"\")\n"
" 19. result of an expression with parentheses and operators + - * / // % ** "
" 20. result of an expression with parentheses and operators + - * / // % ** "
"(format: \"calc:xxx\")\n"
" 20. a random integer number (format: \"random:min,max\")\n"
" 21. a translated string (format: \"translate:xxx\")\n"
" 22. an option (format: \"file.section.option\")\n"
" 23. a local variable in buffer\n"
" 24. a hdata name/variable (the value is automatically converted to "
" 21. a random integer number (format: \"random:min,max\")\n"
" 22. a translated string (format: \"translate:xxx\")\n"
" 23. define a user variable (format: \"define:name,value\")\n"
" 24. an option (format: \"file.section.option\")\n"
" 25. a local variable in buffer\n"
" 26. a hdata name/variable (the value is automatically converted to "
"string), by default \"window\" and \"buffer\" point to current window/"
"buffer.\n"
"Format for hdata can be one of following:\n"
@@ -1678,38 +1680,39 @@ msgid ""
"function \"weechat_hdata_get\".\n"
"\n"
"Examples (simple strings):\n"
" /eval -n ${raw:${info:version}} ==> ${info:version}\n"
" /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
" /eval -n ${info:version} ==> 0.4.3\n"
" /eval -n ${env:HOME} ==> /home/user\n"
" /eval -n ${weechat.look.scroll_amount} ==> 3\n"
" /eval -n ${sec.data.password} ==> secret\n"
" /eval -n ${window} ==> 0x2549aa0\n"
" /eval -n ${window.buffer} ==> 0x2549320\n"
" /eval -n ${window.buffer.full_name} ==> core.weechat\n"
" /eval -n ${window.buffer.number} ==> 1\n"
" /eval -n ${\\t} ==> <tab>\n"
" /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
" /eval -n ${cut:3,+,test} ==> tes+\n"
" /eval -n ${cut:+3,+,test} ==> te+\n"
" /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
" /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
" /eval -n ${rev:Hello} ==> olleH\n"
" /eval -n ${repeat:5,-} ==> -----\n"
" /eval -n ${length:test} ==> 4\n"
" /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
" /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
" /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
" /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
" /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
" /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
" /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${calc:(5+2)*3} ==> 21\n"
" /eval -n ${random:0,10} ==> 3\n"
" /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
" /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
" /eval -n ${translate:Plugin} ==> Extension\n"
" /eval -n ${raw:${info:version}} ==> ${info:version}\n"
" /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
" /eval -n ${info:version} ==> 0.4.3\n"
" /eval -n ${env:HOME} ==> /home/user\n"
" /eval -n ${weechat.look.scroll_amount} ==> 3\n"
" /eval -n ${sec.data.password} ==> secret\n"
" /eval -n ${window} ==> 0x2549aa0\n"
" /eval -n ${window.buffer} ==> 0x2549320\n"
" /eval -n ${window.buffer.full_name} ==> core.weechat\n"
" /eval -n ${window.buffer.number} ==> 1\n"
" /eval -n ${\\t} ==> <tab>\n"
" /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
" /eval -n ${cut:3,+,test} ==> tes+\n"
" /eval -n ${cut:+3,+,test} ==> te+\n"
" /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
" /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
" /eval -n ${rev:Hello} ==> olleH\n"
" /eval -n ${repeat:5,-} ==> -----\n"
" /eval -n ${length:test} ==> 4\n"
" /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
" /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
" /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
" /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
" /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
" /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
" /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${calc:(5+2)*3} ==> 21\n"
" /eval -n ${random:0,10} ==> 3\n"
" /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
" /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
" /eval -n ${translate:Plugin} ==> Extension\n"
" /eval -n ${define:len,${calc:5+3}}${len}x${len} ==> 8x8\n"
"\n"
"Examples (conditions):\n"
" /eval -n -c ${window.buffer.number} > 2 ==> 0\n"
+120 -113
View File
@@ -21,8 +21,8 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2021-09-09 21:07+0200\n"
"PO-Revision-Date: 2021-09-09 21:13+0200\n"
"POT-Creation-Date: 2021-09-20 21:12+0200\n"
"PO-Revision-Date: 2021-09-20 21:13+0200\n"
"Last-Translator: Sébastien Helleu <flashcode@flashtux.org>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
"Language: fr\n"
@@ -1713,36 +1713,38 @@ msgid ""
"Some variables are replaced in expression, using the format ${variable}, "
"variable can be, by order of priority:\n"
" 1. the string itself without evaluation (format: \"raw:xxx\")\n"
" 2. an evaluated sub-string (format: \"eval:xxx\")\n"
" 3. an evaluated condition (format: \"eval_cond:xxx\")\n"
" 4. a string with escaped chars (format: \"esc:xxx\" or \"\\xxx\")\n"
" 5. a string with chars to hide (format: \"hide:char,string\")\n"
" 6. a string with max chars (format: \"cut:max,suffix,string\" or \"cut:"
" 2. a user-defined variable (format: \"name\")\n"
" 3. an evaluated sub-string (format: \"eval:xxx\")\n"
" 4. an evaluated condition (format: \"eval_cond:xxx\")\n"
" 5. a string with escaped chars (format: \"esc:xxx\" or \"\\xxx\")\n"
" 6. a string with chars to hide (format: \"hide:char,string\")\n"
" 7. a string with max chars (format: \"cut:max,suffix,string\" or \"cut:"
"+max,suffix,string\")\n"
" or max chars displayed on screen (format: \"cutscr:max,suffix,string\" "
"or \"cutscr:+max,suffix,string\")\n"
" 7. a reversed string (format: \"rev:xxx\" or \"revscr:xxx\")\n"
" 8. a repeated string (format: \"repeat:count,string\")\n"
" 9. length of a string (format: \"length:xxx\" or \"lengthscr:xxx\")\n"
" 10. split of a string (format: \"split:number,separators,flags,xxx\")\n"
" 11. split of shell argmuents (format: \"split_shell:number,xxx\")\n"
" 12. a color (format: \"color:xxx\", see \"Plugin API reference\", function "
" 8. a reversed string (format: \"rev:xxx\" or \"revscr:xxx\")\n"
" 9. a repeated string (format: \"repeat:count,string\")\n"
" 10. length of a string (format: \"length:xxx\" or \"lengthscr:xxx\")\n"
" 11. split of a string (format: \"split:number,separators,flags,xxx\")\n"
" 12. split of shell argmuents (format: \"split_shell:number,xxx\")\n"
" 13. a color (format: \"color:xxx\", see \"Plugin API reference\", function "
"\"color\")\n"
" 13. a modifier (format: \"modifier:name,data,string\")\n"
" 14. an info (format: \"info:name,arguments\", arguments are optional)\n"
" 15. a base 16/32/64 encoded/decoded string (format: \"base_encode:base,xxx"
" 14. a modifier (format: \"modifier:name,data,string\")\n"
" 15. an info (format: \"info:name,arguments\", arguments are optional)\n"
" 16. a base 16/32/64 encoded/decoded string (format: \"base_encode:base,xxx"
"\" or \"base_decode:base,xxx\")\n"
" 16. current date/time (format: \"date\" or \"date:format\")\n"
" 17. an environment variable (format: \"env:XXX\")\n"
" 18. a ternary operator (format: \"if:condition?value_if_true:value_if_false"
" 17. current date/time (format: \"date\" or \"date:format\")\n"
" 18. an environment variable (format: \"env:XXX\")\n"
" 19. a ternary operator (format: \"if:condition?value_if_true:value_if_false"
"\")\n"
" 19. result of an expression with parentheses and operators + - * / // % ** "
" 20. result of an expression with parentheses and operators + - * / // % ** "
"(format: \"calc:xxx\")\n"
" 20. a random integer number (format: \"random:min,max\")\n"
" 21. a translated string (format: \"translate:xxx\")\n"
" 22. an option (format: \"file.section.option\")\n"
" 23. a local variable in buffer\n"
" 24. a hdata name/variable (the value is automatically converted to "
" 21. a random integer number (format: \"random:min,max\")\n"
" 22. a translated string (format: \"translate:xxx\")\n"
" 23. define a user variable (format: \"define:name,value\")\n"
" 24. an option (format: \"file.section.option\")\n"
" 25. a local variable in buffer\n"
" 26. a hdata name/variable (the value is automatically converted to "
"string), by default \"window\" and \"buffer\" point to current window/"
"buffer.\n"
"Format for hdata can be one of following:\n"
@@ -1764,38 +1766,39 @@ msgid ""
"function \"weechat_hdata_get\".\n"
"\n"
"Examples (simple strings):\n"
" /eval -n ${raw:${info:version}} ==> ${info:version}\n"
" /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
" /eval -n ${info:version} ==> 0.4.3\n"
" /eval -n ${env:HOME} ==> /home/user\n"
" /eval -n ${weechat.look.scroll_amount} ==> 3\n"
" /eval -n ${sec.data.password} ==> secret\n"
" /eval -n ${window} ==> 0x2549aa0\n"
" /eval -n ${window.buffer} ==> 0x2549320\n"
" /eval -n ${window.buffer.full_name} ==> core.weechat\n"
" /eval -n ${window.buffer.number} ==> 1\n"
" /eval -n ${\\t} ==> <tab>\n"
" /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
" /eval -n ${cut:3,+,test} ==> tes+\n"
" /eval -n ${cut:+3,+,test} ==> te+\n"
" /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
" /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
" /eval -n ${rev:Hello} ==> olleH\n"
" /eval -n ${repeat:5,-} ==> -----\n"
" /eval -n ${length:test} ==> 4\n"
" /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
" /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
" /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
" /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
" /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
" /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
" /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${calc:(5+2)*3} ==> 21\n"
" /eval -n ${random:0,10} ==> 3\n"
" /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
" /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
" /eval -n ${translate:Plugin} ==> Extension\n"
" /eval -n ${raw:${info:version}} ==> ${info:version}\n"
" /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
" /eval -n ${info:version} ==> 0.4.3\n"
" /eval -n ${env:HOME} ==> /home/user\n"
" /eval -n ${weechat.look.scroll_amount} ==> 3\n"
" /eval -n ${sec.data.password} ==> secret\n"
" /eval -n ${window} ==> 0x2549aa0\n"
" /eval -n ${window.buffer} ==> 0x2549320\n"
" /eval -n ${window.buffer.full_name} ==> core.weechat\n"
" /eval -n ${window.buffer.number} ==> 1\n"
" /eval -n ${\\t} ==> <tab>\n"
" /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
" /eval -n ${cut:3,+,test} ==> tes+\n"
" /eval -n ${cut:+3,+,test} ==> te+\n"
" /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
" /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
" /eval -n ${rev:Hello} ==> olleH\n"
" /eval -n ${repeat:5,-} ==> -----\n"
" /eval -n ${length:test} ==> 4\n"
" /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
" /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
" /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
" /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
" /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
" /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
" /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${calc:(5+2)*3} ==> 21\n"
" /eval -n ${random:0,10} ==> 3\n"
" /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
" /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
" /eval -n ${translate:Plugin} ==> Extension\n"
" /eval -n ${define:len,${calc:5+3}}${len}x${len} ==> 8x8\n"
"\n"
"Examples (conditions):\n"
" /eval -n -c ${window.buffer.number} > 2 ==> 0\n"
@@ -1861,40 +1864,43 @@ msgstr ""
"Des variables sont remplacées dans l'expression, en utilisant le format "
"${variable}, la variable pouvant être, par ordre de priorité :\n"
" 1. la chaîne elle-même sans évaluation (format : \"raw:xxx\")\n"
" 2. une sous-chaîne évaluée (format : \"eval:xxx\")\n"
" 3. une condition évaluée (format : \"eval_cond:xxx\")\n"
" 4. une chaîne avec les caractères échappés (format : \"esc:xxx\" ou \"\\xxx"
" 2. une variable définie par l'utilisateur (format : \"nom\")\n"
" 3. une sous-chaîne évaluée (format : \"eval:xxx\")\n"
" 4. une condition évaluée (format : \"eval_cond:xxx\")\n"
" 5. une chaîne avec les caractères échappés (format : \"esc:xxx\" ou \"\\xxx"
"\")\n"
" 5. une chaîne avec des caractères à cacher (format : \"hide:caractère,"
" 6. une chaîne avec des caractères à cacher (format : \"hide:caractère,"
"chaîne\")\n"
" 6. une chaîne avec un maximum de caractères (format : \"cut:max,suffixe,"
" 7. une chaîne avec un maximum de caractères (format : \"cut:max,suffixe,"
"chaîne\" ou \"cut:+max,suffixe,chaîne\")\n"
" ou un maximum de caractères affichés à l'écran (format : \"cutscr:max,"
"suffixe,chaîne\" ou \"cutscr:+max,suffixe,chaîne\")\n"
" 7. une chaîne inversée (format : \"rev:xxx\" ou \"revscr:xxx\")\n"
" 8. une chaîne répétée (format : \"repeat:nombre,chaîne\")\n"
" 9. longueur d'une chaîne (format : \"length:xxx\" ou \"lengthscr:xxx\")\n"
" 10. découpage d'une chaîne (format : \"split:nombre,séparateurs,flags,xxx"
" 8. une chaîne inversée (format : \"rev:xxx\" ou \"revscr:xxx\")\n"
" 9. une chaîne répétée (format : \"repeat:nombre,chaîne\")\n"
" 10. longueur d'une chaîne (format : \"length:xxx\" ou \"lengthscr:xxx\")\n"
" 11. découpage d'une chaîne (format : \"split:nombre,séparateurs,flags,xxx"
"\")\n"
" 11. découpage de paramètres shell (format : \"split_shell:nombre,xxx\")\n"
" 12. une couleur (format : \"color:xxx\", voir la \"Référence API extension"
" 12. découpage de paramètres shell (format : \"split_shell:nombre,xxx\")\n"
" 13. une couleur (format : \"color:xxx\", voir la \"Référence API extension"
"\", fonction \"color\")\n"
" 13. un modificateur (format : \"modifier:nom,données,chaîne\")\n"
" 14. une info (format : \"info:nom,paramètres\", les paramètres sont "
" 14. un modificateur (format : \"modifier:nom,données,chaîne\")\n"
" 15. une info (format : \"info:nom,paramètres\", les paramètres sont "
"optionnels)\n"
" 15. une chaîne encodée/decodée en base 16, 32 ou 64 (format : "
" 16. une chaîne encodée/decodée en base 16, 32 ou 64 (format : "
"\"base_encode:base,xxx\" ou \"base_decode:base,xxx\")\n"
" 16. la date/heure courante (format : \"date\" ou \"date:format\")\n"
" 17. une variable d'environnement (format : \"env:XXX\")\n"
" 18. un opérateur ternaire (format : \"if:condition?valeur_si_vrai:"
" 17. la date/heure courante (format : \"date\" ou \"date:format\")\n"
" 18. une variable d'environnement (format : \"env:XXX\")\n"
" 19. un opérateur ternaire (format : \"if:condition?valeur_si_vrai:"
"valeur_si_faux\")\n"
" 19. le résultat d'une expression avec parenthèses et les opérateurs + - "
"* / // % ** (format: \"calc:xxx\")\n"
" 20. un nombre entier aléatoire (format : \"random:min,max\")\n"
" 21. une chaîne traduite (format : \"translate:xxx\")\n"
" 22. une option (format : \"fichier.section.option\")\n"
" 23. une variable locale du tampon\n"
" 24. un hdata/variable (la valeur est automatiquement convertie en chaîne), "
" 20. le résultat d'une expression avec parenthèses et les opérateurs + - "
"* / // % ** (format : \"calc:xxx\")\n"
" 21. un nombre entier aléatoire (format : \"random:min,max\")\n"
" 22. une chaîne traduite (format : \"translate:xxx\")\n"
" 23. déclaration d'une variable utilisateur (format : \"define:nom,valeur"
"\")\n"
" 24. une option (format : \"fichier.section.option\")\n"
" 25. une variable locale du tampon\n"
" 26. un hdata/variable (la valeur est automatiquement convertie en chaîne), "
"par défaut \"window\" et \"buffer\" pointent vers la fenêtre et le tampon "
"courants.\n"
"Le format du hdata peut être le suivant :\n"
@@ -1917,38 +1923,39 @@ msgstr ""
"fonction \"weechat_hdata_get\".\n"
"\n"
"Exemples (chaînes simples) :\n"
" /eval -n ${raw:${info:version}} ==> ${info:version}\n"
" /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
" /eval -n ${info:version} ==> 0.4.3\n"
" /eval -n ${env:HOME} ==> /home/user\n"
" /eval -n ${weechat.look.scroll_amount} ==> 3\n"
" /eval -n ${sec.data.password} ==> secret\n"
" /eval -n ${window} ==> 0x2549aa0\n"
" /eval -n ${window.buffer} ==> 0x2549320\n"
" /eval -n ${window.buffer.full_name} ==> core.weechat\n"
" /eval -n ${window.buffer.number} ==> 1\n"
" /eval -n ${\\t} ==> <tab>\n"
" /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
" /eval -n ${cut:3,+,test} ==> tes+\n"
" /eval -n ${cut:+3,+,test} ==> te+\n"
" /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
" /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
" /eval -n ${rev:Hello} ==> olleH\n"
" /eval -n ${repeat:5,-} ==> -----\n"
" /eval -n ${length:test} ==> 4\n"
" /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
" /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
" /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
" /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
" /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
" /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
" /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${calc:(5+2)*3} ==> 21\n"
" /eval -n ${random:0,10} ==> 3\n"
" /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
" /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
" /eval -n ${translate:Plugin} ==> Extension\n"
" /eval -n ${raw:${info:version}} ==> ${info:version}\n"
" /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
" /eval -n ${info:version} ==> 0.4.3\n"
" /eval -n ${env:HOME} ==> /home/user\n"
" /eval -n ${weechat.look.scroll_amount} ==> 3\n"
" /eval -n ${sec.data.password} ==> secret\n"
" /eval -n ${window} ==> 0x2549aa0\n"
" /eval -n ${window.buffer} ==> 0x2549320\n"
" /eval -n ${window.buffer.full_name} ==> core.weechat\n"
" /eval -n ${window.buffer.number} ==> 1\n"
" /eval -n ${\\t} ==> <tab>\n"
" /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
" /eval -n ${cut:3,+,test} ==> tes+\n"
" /eval -n ${cut:+3,+,test} ==> te+\n"
" /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
" /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
" /eval -n ${rev:Hello} ==> olleH\n"
" /eval -n ${repeat:5,-} ==> -----\n"
" /eval -n ${length:test} ==> 4\n"
" /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
" /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
" /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
" /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
" /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
" /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
" /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${calc:(5+2)*3} ==> 21\n"
" /eval -n ${random:0,10} ==> 3\n"
" /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
" /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
" /eval -n ${translate:Plugin} ==> Extension\n"
" /eval -n ${define:len,${calc:5+3}}${len}x${len} ==> 8x8\n"
"\n"
"Exemples (conditions) :\n"
" /eval -n -c ${window.buffer.number} > 2 ==> 0\n"
+59 -56
View File
@@ -20,7 +20,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2021-09-09 21:07+0200\n"
"POT-Creation-Date: 2021-09-20 21:12+0200\n"
"PO-Revision-Date: 2021-07-10 16:01+0200\n"
"Last-Translator: Andras Voroskoi <voroskoi@frugalware.org>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@@ -1513,36 +1513,38 @@ msgid ""
"Some variables are replaced in expression, using the format ${variable}, "
"variable can be, by order of priority:\n"
" 1. the string itself without evaluation (format: \"raw:xxx\")\n"
" 2. an evaluated sub-string (format: \"eval:xxx\")\n"
" 3. an evaluated condition (format: \"eval_cond:xxx\")\n"
" 4. a string with escaped chars (format: \"esc:xxx\" or \"\\xxx\")\n"
" 5. a string with chars to hide (format: \"hide:char,string\")\n"
" 6. a string with max chars (format: \"cut:max,suffix,string\" or \"cut:"
" 2. a user-defined variable (format: \"name\")\n"
" 3. an evaluated sub-string (format: \"eval:xxx\")\n"
" 4. an evaluated condition (format: \"eval_cond:xxx\")\n"
" 5. a string with escaped chars (format: \"esc:xxx\" or \"\\xxx\")\n"
" 6. a string with chars to hide (format: \"hide:char,string\")\n"
" 7. a string with max chars (format: \"cut:max,suffix,string\" or \"cut:"
"+max,suffix,string\")\n"
" or max chars displayed on screen (format: \"cutscr:max,suffix,string\" "
"or \"cutscr:+max,suffix,string\")\n"
" 7. a reversed string (format: \"rev:xxx\" or \"revscr:xxx\")\n"
" 8. a repeated string (format: \"repeat:count,string\")\n"
" 9. length of a string (format: \"length:xxx\" or \"lengthscr:xxx\")\n"
" 10. split of a string (format: \"split:number,separators,flags,xxx\")\n"
" 11. split of shell argmuents (format: \"split_shell:number,xxx\")\n"
" 12. a color (format: \"color:xxx\", see \"Plugin API reference\", function "
" 8. a reversed string (format: \"rev:xxx\" or \"revscr:xxx\")\n"
" 9. a repeated string (format: \"repeat:count,string\")\n"
" 10. length of a string (format: \"length:xxx\" or \"lengthscr:xxx\")\n"
" 11. split of a string (format: \"split:number,separators,flags,xxx\")\n"
" 12. split of shell argmuents (format: \"split_shell:number,xxx\")\n"
" 13. a color (format: \"color:xxx\", see \"Plugin API reference\", function "
"\"color\")\n"
" 13. a modifier (format: \"modifier:name,data,string\")\n"
" 14. an info (format: \"info:name,arguments\", arguments are optional)\n"
" 15. a base 16/32/64 encoded/decoded string (format: \"base_encode:base,xxx"
" 14. a modifier (format: \"modifier:name,data,string\")\n"
" 15. an info (format: \"info:name,arguments\", arguments are optional)\n"
" 16. a base 16/32/64 encoded/decoded string (format: \"base_encode:base,xxx"
"\" or \"base_decode:base,xxx\")\n"
" 16. current date/time (format: \"date\" or \"date:format\")\n"
" 17. an environment variable (format: \"env:XXX\")\n"
" 18. a ternary operator (format: \"if:condition?value_if_true:value_if_false"
" 17. current date/time (format: \"date\" or \"date:format\")\n"
" 18. an environment variable (format: \"env:XXX\")\n"
" 19. a ternary operator (format: \"if:condition?value_if_true:value_if_false"
"\")\n"
" 19. result of an expression with parentheses and operators + - * / // % ** "
" 20. result of an expression with parentheses and operators + - * / // % ** "
"(format: \"calc:xxx\")\n"
" 20. a random integer number (format: \"random:min,max\")\n"
" 21. a translated string (format: \"translate:xxx\")\n"
" 22. an option (format: \"file.section.option\")\n"
" 23. a local variable in buffer\n"
" 24. a hdata name/variable (the value is automatically converted to "
" 21. a random integer number (format: \"random:min,max\")\n"
" 22. a translated string (format: \"translate:xxx\")\n"
" 23. define a user variable (format: \"define:name,value\")\n"
" 24. an option (format: \"file.section.option\")\n"
" 25. a local variable in buffer\n"
" 26. a hdata name/variable (the value is automatically converted to "
"string), by default \"window\" and \"buffer\" point to current window/"
"buffer.\n"
"Format for hdata can be one of following:\n"
@@ -1564,38 +1566,39 @@ msgid ""
"function \"weechat_hdata_get\".\n"
"\n"
"Examples (simple strings):\n"
" /eval -n ${raw:${info:version}} ==> ${info:version}\n"
" /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
" /eval -n ${info:version} ==> 0.4.3\n"
" /eval -n ${env:HOME} ==> /home/user\n"
" /eval -n ${weechat.look.scroll_amount} ==> 3\n"
" /eval -n ${sec.data.password} ==> secret\n"
" /eval -n ${window} ==> 0x2549aa0\n"
" /eval -n ${window.buffer} ==> 0x2549320\n"
" /eval -n ${window.buffer.full_name} ==> core.weechat\n"
" /eval -n ${window.buffer.number} ==> 1\n"
" /eval -n ${\\t} ==> <tab>\n"
" /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
" /eval -n ${cut:3,+,test} ==> tes+\n"
" /eval -n ${cut:+3,+,test} ==> te+\n"
" /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
" /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
" /eval -n ${rev:Hello} ==> olleH\n"
" /eval -n ${repeat:5,-} ==> -----\n"
" /eval -n ${length:test} ==> 4\n"
" /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
" /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
" /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
" /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
" /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
" /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
" /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${calc:(5+2)*3} ==> 21\n"
" /eval -n ${random:0,10} ==> 3\n"
" /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
" /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
" /eval -n ${translate:Plugin} ==> Extension\n"
" /eval -n ${raw:${info:version}} ==> ${info:version}\n"
" /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
" /eval -n ${info:version} ==> 0.4.3\n"
" /eval -n ${env:HOME} ==> /home/user\n"
" /eval -n ${weechat.look.scroll_amount} ==> 3\n"
" /eval -n ${sec.data.password} ==> secret\n"
" /eval -n ${window} ==> 0x2549aa0\n"
" /eval -n ${window.buffer} ==> 0x2549320\n"
" /eval -n ${window.buffer.full_name} ==> core.weechat\n"
" /eval -n ${window.buffer.number} ==> 1\n"
" /eval -n ${\\t} ==> <tab>\n"
" /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
" /eval -n ${cut:3,+,test} ==> tes+\n"
" /eval -n ${cut:+3,+,test} ==> te+\n"
" /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
" /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
" /eval -n ${rev:Hello} ==> olleH\n"
" /eval -n ${repeat:5,-} ==> -----\n"
" /eval -n ${length:test} ==> 4\n"
" /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
" /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
" /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
" /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
" /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
" /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
" /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${calc:(5+2)*3} ==> 21\n"
" /eval -n ${random:0,10} ==> 3\n"
" /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
" /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
" /eval -n ${translate:Plugin} ==> Extension\n"
" /eval -n ${define:len,${calc:5+3}}${len}x${len} ==> 8x8\n"
"\n"
"Examples (conditions):\n"
" /eval -n -c ${window.buffer.number} > 2 ==> 0\n"
+59 -56
View File
@@ -20,7 +20,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2021-09-09 21:07+0200\n"
"POT-Creation-Date: 2021-09-20 21:12+0200\n"
"PO-Revision-Date: 2021-07-10 16:01+0200\n"
"Last-Translator: Esteban I. Ruiz Moreno <exio4.com@gmail.com>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@@ -1610,36 +1610,38 @@ msgid ""
"Some variables are replaced in expression, using the format ${variable}, "
"variable can be, by order of priority:\n"
" 1. the string itself without evaluation (format: \"raw:xxx\")\n"
" 2. an evaluated sub-string (format: \"eval:xxx\")\n"
" 3. an evaluated condition (format: \"eval_cond:xxx\")\n"
" 4. a string with escaped chars (format: \"esc:xxx\" or \"\\xxx\")\n"
" 5. a string with chars to hide (format: \"hide:char,string\")\n"
" 6. a string with max chars (format: \"cut:max,suffix,string\" or \"cut:"
" 2. a user-defined variable (format: \"name\")\n"
" 3. an evaluated sub-string (format: \"eval:xxx\")\n"
" 4. an evaluated condition (format: \"eval_cond:xxx\")\n"
" 5. a string with escaped chars (format: \"esc:xxx\" or \"\\xxx\")\n"
" 6. a string with chars to hide (format: \"hide:char,string\")\n"
" 7. a string with max chars (format: \"cut:max,suffix,string\" or \"cut:"
"+max,suffix,string\")\n"
" or max chars displayed on screen (format: \"cutscr:max,suffix,string\" "
"or \"cutscr:+max,suffix,string\")\n"
" 7. a reversed string (format: \"rev:xxx\" or \"revscr:xxx\")\n"
" 8. a repeated string (format: \"repeat:count,string\")\n"
" 9. length of a string (format: \"length:xxx\" or \"lengthscr:xxx\")\n"
" 10. split of a string (format: \"split:number,separators,flags,xxx\")\n"
" 11. split of shell argmuents (format: \"split_shell:number,xxx\")\n"
" 12. a color (format: \"color:xxx\", see \"Plugin API reference\", function "
" 8. a reversed string (format: \"rev:xxx\" or \"revscr:xxx\")\n"
" 9. a repeated string (format: \"repeat:count,string\")\n"
" 10. length of a string (format: \"length:xxx\" or \"lengthscr:xxx\")\n"
" 11. split of a string (format: \"split:number,separators,flags,xxx\")\n"
" 12. split of shell argmuents (format: \"split_shell:number,xxx\")\n"
" 13. a color (format: \"color:xxx\", see \"Plugin API reference\", function "
"\"color\")\n"
" 13. a modifier (format: \"modifier:name,data,string\")\n"
" 14. an info (format: \"info:name,arguments\", arguments are optional)\n"
" 15. a base 16/32/64 encoded/decoded string (format: \"base_encode:base,xxx"
" 14. a modifier (format: \"modifier:name,data,string\")\n"
" 15. an info (format: \"info:name,arguments\", arguments are optional)\n"
" 16. a base 16/32/64 encoded/decoded string (format: \"base_encode:base,xxx"
"\" or \"base_decode:base,xxx\")\n"
" 16. current date/time (format: \"date\" or \"date:format\")\n"
" 17. an environment variable (format: \"env:XXX\")\n"
" 18. a ternary operator (format: \"if:condition?value_if_true:value_if_false"
" 17. current date/time (format: \"date\" or \"date:format\")\n"
" 18. an environment variable (format: \"env:XXX\")\n"
" 19. a ternary operator (format: \"if:condition?value_if_true:value_if_false"
"\")\n"
" 19. result of an expression with parentheses and operators + - * / // % ** "
" 20. result of an expression with parentheses and operators + - * / // % ** "
"(format: \"calc:xxx\")\n"
" 20. a random integer number (format: \"random:min,max\")\n"
" 21. a translated string (format: \"translate:xxx\")\n"
" 22. an option (format: \"file.section.option\")\n"
" 23. a local variable in buffer\n"
" 24. a hdata name/variable (the value is automatically converted to "
" 21. a random integer number (format: \"random:min,max\")\n"
" 22. a translated string (format: \"translate:xxx\")\n"
" 23. define a user variable (format: \"define:name,value\")\n"
" 24. an option (format: \"file.section.option\")\n"
" 25. a local variable in buffer\n"
" 26. a hdata name/variable (the value is automatically converted to "
"string), by default \"window\" and \"buffer\" point to current window/"
"buffer.\n"
"Format for hdata can be one of following:\n"
@@ -1661,38 +1663,39 @@ msgid ""
"function \"weechat_hdata_get\".\n"
"\n"
"Examples (simple strings):\n"
" /eval -n ${raw:${info:version}} ==> ${info:version}\n"
" /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
" /eval -n ${info:version} ==> 0.4.3\n"
" /eval -n ${env:HOME} ==> /home/user\n"
" /eval -n ${weechat.look.scroll_amount} ==> 3\n"
" /eval -n ${sec.data.password} ==> secret\n"
" /eval -n ${window} ==> 0x2549aa0\n"
" /eval -n ${window.buffer} ==> 0x2549320\n"
" /eval -n ${window.buffer.full_name} ==> core.weechat\n"
" /eval -n ${window.buffer.number} ==> 1\n"
" /eval -n ${\\t} ==> <tab>\n"
" /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
" /eval -n ${cut:3,+,test} ==> tes+\n"
" /eval -n ${cut:+3,+,test} ==> te+\n"
" /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
" /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
" /eval -n ${rev:Hello} ==> olleH\n"
" /eval -n ${repeat:5,-} ==> -----\n"
" /eval -n ${length:test} ==> 4\n"
" /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
" /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
" /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
" /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
" /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
" /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
" /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${calc:(5+2)*3} ==> 21\n"
" /eval -n ${random:0,10} ==> 3\n"
" /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
" /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
" /eval -n ${translate:Plugin} ==> Extension\n"
" /eval -n ${raw:${info:version}} ==> ${info:version}\n"
" /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
" /eval -n ${info:version} ==> 0.4.3\n"
" /eval -n ${env:HOME} ==> /home/user\n"
" /eval -n ${weechat.look.scroll_amount} ==> 3\n"
" /eval -n ${sec.data.password} ==> secret\n"
" /eval -n ${window} ==> 0x2549aa0\n"
" /eval -n ${window.buffer} ==> 0x2549320\n"
" /eval -n ${window.buffer.full_name} ==> core.weechat\n"
" /eval -n ${window.buffer.number} ==> 1\n"
" /eval -n ${\\t} ==> <tab>\n"
" /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
" /eval -n ${cut:3,+,test} ==> tes+\n"
" /eval -n ${cut:+3,+,test} ==> te+\n"
" /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
" /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
" /eval -n ${rev:Hello} ==> olleH\n"
" /eval -n ${repeat:5,-} ==> -----\n"
" /eval -n ${length:test} ==> 4\n"
" /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
" /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
" /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
" /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
" /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
" /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
" /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${calc:(5+2)*3} ==> 21\n"
" /eval -n ${random:0,10} ==> 3\n"
" /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
" /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
" /eval -n ${translate:Plugin} ==> Extension\n"
" /eval -n ${define:len,${calc:5+3}}${len}x${len} ==> 8x8\n"
"\n"
"Examples (conditions):\n"
" /eval -n -c ${window.buffer.number} > 2 ==> 0\n"
+59 -56
View File
@@ -20,7 +20,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2021-09-09 21:07+0200\n"
"POT-Creation-Date: 2021-09-20 21:12+0200\n"
"PO-Revision-Date: 2021-07-10 16:01+0200\n"
"Last-Translator: AYANOKOUZI, Ryuunosuke <i38w7i3@yahoo.co.jp>\n"
"Language-Team: Japanese <https://github.com/l/weechat/tree/master/"
@@ -1694,36 +1694,38 @@ msgid ""
"Some variables are replaced in expression, using the format ${variable}, "
"variable can be, by order of priority:\n"
" 1. the string itself without evaluation (format: \"raw:xxx\")\n"
" 2. an evaluated sub-string (format: \"eval:xxx\")\n"
" 3. an evaluated condition (format: \"eval_cond:xxx\")\n"
" 4. a string with escaped chars (format: \"esc:xxx\" or \"\\xxx\")\n"
" 5. a string with chars to hide (format: \"hide:char,string\")\n"
" 6. a string with max chars (format: \"cut:max,suffix,string\" or \"cut:"
" 2. a user-defined variable (format: \"name\")\n"
" 3. an evaluated sub-string (format: \"eval:xxx\")\n"
" 4. an evaluated condition (format: \"eval_cond:xxx\")\n"
" 5. a string with escaped chars (format: \"esc:xxx\" or \"\\xxx\")\n"
" 6. a string with chars to hide (format: \"hide:char,string\")\n"
" 7. a string with max chars (format: \"cut:max,suffix,string\" or \"cut:"
"+max,suffix,string\")\n"
" or max chars displayed on screen (format: \"cutscr:max,suffix,string\" "
"or \"cutscr:+max,suffix,string\")\n"
" 7. a reversed string (format: \"rev:xxx\" or \"revscr:xxx\")\n"
" 8. a repeated string (format: \"repeat:count,string\")\n"
" 9. length of a string (format: \"length:xxx\" or \"lengthscr:xxx\")\n"
" 10. split of a string (format: \"split:number,separators,flags,xxx\")\n"
" 11. split of shell argmuents (format: \"split_shell:number,xxx\")\n"
" 12. a color (format: \"color:xxx\", see \"Plugin API reference\", function "
" 8. a reversed string (format: \"rev:xxx\" or \"revscr:xxx\")\n"
" 9. a repeated string (format: \"repeat:count,string\")\n"
" 10. length of a string (format: \"length:xxx\" or \"lengthscr:xxx\")\n"
" 11. split of a string (format: \"split:number,separators,flags,xxx\")\n"
" 12. split of shell argmuents (format: \"split_shell:number,xxx\")\n"
" 13. a color (format: \"color:xxx\", see \"Plugin API reference\", function "
"\"color\")\n"
" 13. a modifier (format: \"modifier:name,data,string\")\n"
" 14. an info (format: \"info:name,arguments\", arguments are optional)\n"
" 15. a base 16/32/64 encoded/decoded string (format: \"base_encode:base,xxx"
" 14. a modifier (format: \"modifier:name,data,string\")\n"
" 15. an info (format: \"info:name,arguments\", arguments are optional)\n"
" 16. a base 16/32/64 encoded/decoded string (format: \"base_encode:base,xxx"
"\" or \"base_decode:base,xxx\")\n"
" 16. current date/time (format: \"date\" or \"date:format\")\n"
" 17. an environment variable (format: \"env:XXX\")\n"
" 18. a ternary operator (format: \"if:condition?value_if_true:value_if_false"
" 17. current date/time (format: \"date\" or \"date:format\")\n"
" 18. an environment variable (format: \"env:XXX\")\n"
" 19. a ternary operator (format: \"if:condition?value_if_true:value_if_false"
"\")\n"
" 19. result of an expression with parentheses and operators + - * / // % ** "
" 20. result of an expression with parentheses and operators + - * / // % ** "
"(format: \"calc:xxx\")\n"
" 20. a random integer number (format: \"random:min,max\")\n"
" 21. a translated string (format: \"translate:xxx\")\n"
" 22. an option (format: \"file.section.option\")\n"
" 23. a local variable in buffer\n"
" 24. a hdata name/variable (the value is automatically converted to "
" 21. a random integer number (format: \"random:min,max\")\n"
" 22. a translated string (format: \"translate:xxx\")\n"
" 23. define a user variable (format: \"define:name,value\")\n"
" 24. an option (format: \"file.section.option\")\n"
" 25. a local variable in buffer\n"
" 26. a hdata name/variable (the value is automatically converted to "
"string), by default \"window\" and \"buffer\" point to current window/"
"buffer.\n"
"Format for hdata can be one of following:\n"
@@ -1745,38 +1747,39 @@ msgid ""
"function \"weechat_hdata_get\".\n"
"\n"
"Examples (simple strings):\n"
" /eval -n ${raw:${info:version}} ==> ${info:version}\n"
" /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
" /eval -n ${info:version} ==> 0.4.3\n"
" /eval -n ${env:HOME} ==> /home/user\n"
" /eval -n ${weechat.look.scroll_amount} ==> 3\n"
" /eval -n ${sec.data.password} ==> secret\n"
" /eval -n ${window} ==> 0x2549aa0\n"
" /eval -n ${window.buffer} ==> 0x2549320\n"
" /eval -n ${window.buffer.full_name} ==> core.weechat\n"
" /eval -n ${window.buffer.number} ==> 1\n"
" /eval -n ${\\t} ==> <tab>\n"
" /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
" /eval -n ${cut:3,+,test} ==> tes+\n"
" /eval -n ${cut:+3,+,test} ==> te+\n"
" /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
" /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
" /eval -n ${rev:Hello} ==> olleH\n"
" /eval -n ${repeat:5,-} ==> -----\n"
" /eval -n ${length:test} ==> 4\n"
" /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
" /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
" /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
" /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
" /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
" /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
" /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${calc:(5+2)*3} ==> 21\n"
" /eval -n ${random:0,10} ==> 3\n"
" /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
" /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
" /eval -n ${translate:Plugin} ==> Extension\n"
" /eval -n ${raw:${info:version}} ==> ${info:version}\n"
" /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
" /eval -n ${info:version} ==> 0.4.3\n"
" /eval -n ${env:HOME} ==> /home/user\n"
" /eval -n ${weechat.look.scroll_amount} ==> 3\n"
" /eval -n ${sec.data.password} ==> secret\n"
" /eval -n ${window} ==> 0x2549aa0\n"
" /eval -n ${window.buffer} ==> 0x2549320\n"
" /eval -n ${window.buffer.full_name} ==> core.weechat\n"
" /eval -n ${window.buffer.number} ==> 1\n"
" /eval -n ${\\t} ==> <tab>\n"
" /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
" /eval -n ${cut:3,+,test} ==> tes+\n"
" /eval -n ${cut:+3,+,test} ==> te+\n"
" /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
" /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
" /eval -n ${rev:Hello} ==> olleH\n"
" /eval -n ${repeat:5,-} ==> -----\n"
" /eval -n ${length:test} ==> 4\n"
" /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
" /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
" /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
" /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
" /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
" /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
" /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${calc:(5+2)*3} ==> 21\n"
" /eval -n ${random:0,10} ==> 3\n"
" /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
" /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
" /eval -n ${translate:Plugin} ==> Extension\n"
" /eval -n ${define:len,${calc:5+3}}${len}x${len} ==> 8x8\n"
"\n"
"Examples (conditions):\n"
" /eval -n -c ${window.buffer.number} > 2 ==> 0\n"
+59 -56
View File
@@ -22,7 +22,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2021-09-09 21:07+0200\n"
"POT-Creation-Date: 2021-09-20 21:12+0200\n"
"PO-Revision-Date: 2021-07-10 16:01+0200\n"
"Last-Translator: Krzysztof Korościk <soltys@soltys.info>\n"
"Language-Team: Polish <kde-i18n-doc@kde.org>\n"
@@ -1844,36 +1844,38 @@ msgid ""
"Some variables are replaced in expression, using the format ${variable}, "
"variable can be, by order of priority:\n"
" 1. the string itself without evaluation (format: \"raw:xxx\")\n"
" 2. an evaluated sub-string (format: \"eval:xxx\")\n"
" 3. an evaluated condition (format: \"eval_cond:xxx\")\n"
" 4. a string with escaped chars (format: \"esc:xxx\" or \"\\xxx\")\n"
" 5. a string with chars to hide (format: \"hide:char,string\")\n"
" 6. a string with max chars (format: \"cut:max,suffix,string\" or \"cut:"
" 2. a user-defined variable (format: \"name\")\n"
" 3. an evaluated sub-string (format: \"eval:xxx\")\n"
" 4. an evaluated condition (format: \"eval_cond:xxx\")\n"
" 5. a string with escaped chars (format: \"esc:xxx\" or \"\\xxx\")\n"
" 6. a string with chars to hide (format: \"hide:char,string\")\n"
" 7. a string with max chars (format: \"cut:max,suffix,string\" or \"cut:"
"+max,suffix,string\")\n"
" or max chars displayed on screen (format: \"cutscr:max,suffix,string\" "
"or \"cutscr:+max,suffix,string\")\n"
" 7. a reversed string (format: \"rev:xxx\" or \"revscr:xxx\")\n"
" 8. a repeated string (format: \"repeat:count,string\")\n"
" 9. length of a string (format: \"length:xxx\" or \"lengthscr:xxx\")\n"
" 10. split of a string (format: \"split:number,separators,flags,xxx\")\n"
" 11. split of shell argmuents (format: \"split_shell:number,xxx\")\n"
" 12. a color (format: \"color:xxx\", see \"Plugin API reference\", function "
" 8. a reversed string (format: \"rev:xxx\" or \"revscr:xxx\")\n"
" 9. a repeated string (format: \"repeat:count,string\")\n"
" 10. length of a string (format: \"length:xxx\" or \"lengthscr:xxx\")\n"
" 11. split of a string (format: \"split:number,separators,flags,xxx\")\n"
" 12. split of shell argmuents (format: \"split_shell:number,xxx\")\n"
" 13. a color (format: \"color:xxx\", see \"Plugin API reference\", function "
"\"color\")\n"
" 13. a modifier (format: \"modifier:name,data,string\")\n"
" 14. an info (format: \"info:name,arguments\", arguments are optional)\n"
" 15. a base 16/32/64 encoded/decoded string (format: \"base_encode:base,xxx"
" 14. a modifier (format: \"modifier:name,data,string\")\n"
" 15. an info (format: \"info:name,arguments\", arguments are optional)\n"
" 16. a base 16/32/64 encoded/decoded string (format: \"base_encode:base,xxx"
"\" or \"base_decode:base,xxx\")\n"
" 16. current date/time (format: \"date\" or \"date:format\")\n"
" 17. an environment variable (format: \"env:XXX\")\n"
" 18. a ternary operator (format: \"if:condition?value_if_true:value_if_false"
" 17. current date/time (format: \"date\" or \"date:format\")\n"
" 18. an environment variable (format: \"env:XXX\")\n"
" 19. a ternary operator (format: \"if:condition?value_if_true:value_if_false"
"\")\n"
" 19. result of an expression with parentheses and operators + - * / // % ** "
" 20. result of an expression with parentheses and operators + - * / // % ** "
"(format: \"calc:xxx\")\n"
" 20. a random integer number (format: \"random:min,max\")\n"
" 21. a translated string (format: \"translate:xxx\")\n"
" 22. an option (format: \"file.section.option\")\n"
" 23. a local variable in buffer\n"
" 24. a hdata name/variable (the value is automatically converted to "
" 21. a random integer number (format: \"random:min,max\")\n"
" 22. a translated string (format: \"translate:xxx\")\n"
" 23. define a user variable (format: \"define:name,value\")\n"
" 24. an option (format: \"file.section.option\")\n"
" 25. a local variable in buffer\n"
" 26. a hdata name/variable (the value is automatically converted to "
"string), by default \"window\" and \"buffer\" point to current window/"
"buffer.\n"
"Format for hdata can be one of following:\n"
@@ -1895,38 +1897,39 @@ msgid ""
"function \"weechat_hdata_get\".\n"
"\n"
"Examples (simple strings):\n"
" /eval -n ${raw:${info:version}} ==> ${info:version}\n"
" /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
" /eval -n ${info:version} ==> 0.4.3\n"
" /eval -n ${env:HOME} ==> /home/user\n"
" /eval -n ${weechat.look.scroll_amount} ==> 3\n"
" /eval -n ${sec.data.password} ==> secret\n"
" /eval -n ${window} ==> 0x2549aa0\n"
" /eval -n ${window.buffer} ==> 0x2549320\n"
" /eval -n ${window.buffer.full_name} ==> core.weechat\n"
" /eval -n ${window.buffer.number} ==> 1\n"
" /eval -n ${\\t} ==> <tab>\n"
" /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
" /eval -n ${cut:3,+,test} ==> tes+\n"
" /eval -n ${cut:+3,+,test} ==> te+\n"
" /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
" /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
" /eval -n ${rev:Hello} ==> olleH\n"
" /eval -n ${repeat:5,-} ==> -----\n"
" /eval -n ${length:test} ==> 4\n"
" /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
" /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
" /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
" /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
" /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
" /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
" /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${calc:(5+2)*3} ==> 21\n"
" /eval -n ${random:0,10} ==> 3\n"
" /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
" /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
" /eval -n ${translate:Plugin} ==> Extension\n"
" /eval -n ${raw:${info:version}} ==> ${info:version}\n"
" /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
" /eval -n ${info:version} ==> 0.4.3\n"
" /eval -n ${env:HOME} ==> /home/user\n"
" /eval -n ${weechat.look.scroll_amount} ==> 3\n"
" /eval -n ${sec.data.password} ==> secret\n"
" /eval -n ${window} ==> 0x2549aa0\n"
" /eval -n ${window.buffer} ==> 0x2549320\n"
" /eval -n ${window.buffer.full_name} ==> core.weechat\n"
" /eval -n ${window.buffer.number} ==> 1\n"
" /eval -n ${\\t} ==> <tab>\n"
" /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
" /eval -n ${cut:3,+,test} ==> tes+\n"
" /eval -n ${cut:+3,+,test} ==> te+\n"
" /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
" /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
" /eval -n ${rev:Hello} ==> olleH\n"
" /eval -n ${repeat:5,-} ==> -----\n"
" /eval -n ${length:test} ==> 4\n"
" /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
" /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
" /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
" /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
" /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
" /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
" /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${calc:(5+2)*3} ==> 21\n"
" /eval -n ${random:0,10} ==> 3\n"
" /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
" /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
" /eval -n ${translate:Plugin} ==> Extension\n"
" /eval -n ${define:len,${calc:5+3}}${len}x${len} ==> 8x8\n"
"\n"
"Examples (conditions):\n"
" /eval -n -c ${window.buffer.number} > 2 ==> 0\n"
+59 -56
View File
@@ -20,7 +20,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2021-09-09 21:07+0200\n"
"POT-Creation-Date: 2021-09-20 21:12+0200\n"
"PO-Revision-Date: 2021-07-10 16:01+0200\n"
"Last-Translator: Vasco Almeida <vascomalmeida@sapo.pt>\n"
"Language-Team: Portuguese <>\n"
@@ -1698,36 +1698,38 @@ msgid ""
"Some variables are replaced in expression, using the format ${variable}, "
"variable can be, by order of priority:\n"
" 1. the string itself without evaluation (format: \"raw:xxx\")\n"
" 2. an evaluated sub-string (format: \"eval:xxx\")\n"
" 3. an evaluated condition (format: \"eval_cond:xxx\")\n"
" 4. a string with escaped chars (format: \"esc:xxx\" or \"\\xxx\")\n"
" 5. a string with chars to hide (format: \"hide:char,string\")\n"
" 6. a string with max chars (format: \"cut:max,suffix,string\" or \"cut:"
" 2. a user-defined variable (format: \"name\")\n"
" 3. an evaluated sub-string (format: \"eval:xxx\")\n"
" 4. an evaluated condition (format: \"eval_cond:xxx\")\n"
" 5. a string with escaped chars (format: \"esc:xxx\" or \"\\xxx\")\n"
" 6. a string with chars to hide (format: \"hide:char,string\")\n"
" 7. a string with max chars (format: \"cut:max,suffix,string\" or \"cut:"
"+max,suffix,string\")\n"
" or max chars displayed on screen (format: \"cutscr:max,suffix,string\" "
"or \"cutscr:+max,suffix,string\")\n"
" 7. a reversed string (format: \"rev:xxx\" or \"revscr:xxx\")\n"
" 8. a repeated string (format: \"repeat:count,string\")\n"
" 9. length of a string (format: \"length:xxx\" or \"lengthscr:xxx\")\n"
" 10. split of a string (format: \"split:number,separators,flags,xxx\")\n"
" 11. split of shell argmuents (format: \"split_shell:number,xxx\")\n"
" 12. a color (format: \"color:xxx\", see \"Plugin API reference\", function "
" 8. a reversed string (format: \"rev:xxx\" or \"revscr:xxx\")\n"
" 9. a repeated string (format: \"repeat:count,string\")\n"
" 10. length of a string (format: \"length:xxx\" or \"lengthscr:xxx\")\n"
" 11. split of a string (format: \"split:number,separators,flags,xxx\")\n"
" 12. split of shell argmuents (format: \"split_shell:number,xxx\")\n"
" 13. a color (format: \"color:xxx\", see \"Plugin API reference\", function "
"\"color\")\n"
" 13. a modifier (format: \"modifier:name,data,string\")\n"
" 14. an info (format: \"info:name,arguments\", arguments are optional)\n"
" 15. a base 16/32/64 encoded/decoded string (format: \"base_encode:base,xxx"
" 14. a modifier (format: \"modifier:name,data,string\")\n"
" 15. an info (format: \"info:name,arguments\", arguments are optional)\n"
" 16. a base 16/32/64 encoded/decoded string (format: \"base_encode:base,xxx"
"\" or \"base_decode:base,xxx\")\n"
" 16. current date/time (format: \"date\" or \"date:format\")\n"
" 17. an environment variable (format: \"env:XXX\")\n"
" 18. a ternary operator (format: \"if:condition?value_if_true:value_if_false"
" 17. current date/time (format: \"date\" or \"date:format\")\n"
" 18. an environment variable (format: \"env:XXX\")\n"
" 19. a ternary operator (format: \"if:condition?value_if_true:value_if_false"
"\")\n"
" 19. result of an expression with parentheses and operators + - * / // % ** "
" 20. result of an expression with parentheses and operators + - * / // % ** "
"(format: \"calc:xxx\")\n"
" 20. a random integer number (format: \"random:min,max\")\n"
" 21. a translated string (format: \"translate:xxx\")\n"
" 22. an option (format: \"file.section.option\")\n"
" 23. a local variable in buffer\n"
" 24. a hdata name/variable (the value is automatically converted to "
" 21. a random integer number (format: \"random:min,max\")\n"
" 22. a translated string (format: \"translate:xxx\")\n"
" 23. define a user variable (format: \"define:name,value\")\n"
" 24. an option (format: \"file.section.option\")\n"
" 25. a local variable in buffer\n"
" 26. a hdata name/variable (the value is automatically converted to "
"string), by default \"window\" and \"buffer\" point to current window/"
"buffer.\n"
"Format for hdata can be one of following:\n"
@@ -1749,38 +1751,39 @@ msgid ""
"function \"weechat_hdata_get\".\n"
"\n"
"Examples (simple strings):\n"
" /eval -n ${raw:${info:version}} ==> ${info:version}\n"
" /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
" /eval -n ${info:version} ==> 0.4.3\n"
" /eval -n ${env:HOME} ==> /home/user\n"
" /eval -n ${weechat.look.scroll_amount} ==> 3\n"
" /eval -n ${sec.data.password} ==> secret\n"
" /eval -n ${window} ==> 0x2549aa0\n"
" /eval -n ${window.buffer} ==> 0x2549320\n"
" /eval -n ${window.buffer.full_name} ==> core.weechat\n"
" /eval -n ${window.buffer.number} ==> 1\n"
" /eval -n ${\\t} ==> <tab>\n"
" /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
" /eval -n ${cut:3,+,test} ==> tes+\n"
" /eval -n ${cut:+3,+,test} ==> te+\n"
" /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
" /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
" /eval -n ${rev:Hello} ==> olleH\n"
" /eval -n ${repeat:5,-} ==> -----\n"
" /eval -n ${length:test} ==> 4\n"
" /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
" /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
" /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
" /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
" /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
" /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
" /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${calc:(5+2)*3} ==> 21\n"
" /eval -n ${random:0,10} ==> 3\n"
" /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
" /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
" /eval -n ${translate:Plugin} ==> Extension\n"
" /eval -n ${raw:${info:version}} ==> ${info:version}\n"
" /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
" /eval -n ${info:version} ==> 0.4.3\n"
" /eval -n ${env:HOME} ==> /home/user\n"
" /eval -n ${weechat.look.scroll_amount} ==> 3\n"
" /eval -n ${sec.data.password} ==> secret\n"
" /eval -n ${window} ==> 0x2549aa0\n"
" /eval -n ${window.buffer} ==> 0x2549320\n"
" /eval -n ${window.buffer.full_name} ==> core.weechat\n"
" /eval -n ${window.buffer.number} ==> 1\n"
" /eval -n ${\\t} ==> <tab>\n"
" /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
" /eval -n ${cut:3,+,test} ==> tes+\n"
" /eval -n ${cut:+3,+,test} ==> te+\n"
" /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
" /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
" /eval -n ${rev:Hello} ==> olleH\n"
" /eval -n ${repeat:5,-} ==> -----\n"
" /eval -n ${length:test} ==> 4\n"
" /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
" /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
" /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
" /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
" /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
" /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
" /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${calc:(5+2)*3} ==> 21\n"
" /eval -n ${random:0,10} ==> 3\n"
" /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
" /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
" /eval -n ${translate:Plugin} ==> Extension\n"
" /eval -n ${define:len,${calc:5+3}}${len}x${len} ==> 8x8\n"
"\n"
"Examples (conditions):\n"
" /eval -n -c ${window.buffer.number} > 2 ==> 0\n"
+59 -56
View File
@@ -21,7 +21,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2021-09-09 21:07+0200\n"
"POT-Creation-Date: 2021-09-20 21:12+0200\n"
"PO-Revision-Date: 2021-07-10 16:01+0200\n"
"Last-Translator: Érico Nogueira <ericonr@disroot.org>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@@ -1673,36 +1673,38 @@ msgid ""
"Some variables are replaced in expression, using the format ${variable}, "
"variable can be, by order of priority:\n"
" 1. the string itself without evaluation (format: \"raw:xxx\")\n"
" 2. an evaluated sub-string (format: \"eval:xxx\")\n"
" 3. an evaluated condition (format: \"eval_cond:xxx\")\n"
" 4. a string with escaped chars (format: \"esc:xxx\" or \"\\xxx\")\n"
" 5. a string with chars to hide (format: \"hide:char,string\")\n"
" 6. a string with max chars (format: \"cut:max,suffix,string\" or \"cut:"
" 2. a user-defined variable (format: \"name\")\n"
" 3. an evaluated sub-string (format: \"eval:xxx\")\n"
" 4. an evaluated condition (format: \"eval_cond:xxx\")\n"
" 5. a string with escaped chars (format: \"esc:xxx\" or \"\\xxx\")\n"
" 6. a string with chars to hide (format: \"hide:char,string\")\n"
" 7. a string with max chars (format: \"cut:max,suffix,string\" or \"cut:"
"+max,suffix,string\")\n"
" or max chars displayed on screen (format: \"cutscr:max,suffix,string\" "
"or \"cutscr:+max,suffix,string\")\n"
" 7. a reversed string (format: \"rev:xxx\" or \"revscr:xxx\")\n"
" 8. a repeated string (format: \"repeat:count,string\")\n"
" 9. length of a string (format: \"length:xxx\" or \"lengthscr:xxx\")\n"
" 10. split of a string (format: \"split:number,separators,flags,xxx\")\n"
" 11. split of shell argmuents (format: \"split_shell:number,xxx\")\n"
" 12. a color (format: \"color:xxx\", see \"Plugin API reference\", function "
" 8. a reversed string (format: \"rev:xxx\" or \"revscr:xxx\")\n"
" 9. a repeated string (format: \"repeat:count,string\")\n"
" 10. length of a string (format: \"length:xxx\" or \"lengthscr:xxx\")\n"
" 11. split of a string (format: \"split:number,separators,flags,xxx\")\n"
" 12. split of shell argmuents (format: \"split_shell:number,xxx\")\n"
" 13. a color (format: \"color:xxx\", see \"Plugin API reference\", function "
"\"color\")\n"
" 13. a modifier (format: \"modifier:name,data,string\")\n"
" 14. an info (format: \"info:name,arguments\", arguments are optional)\n"
" 15. a base 16/32/64 encoded/decoded string (format: \"base_encode:base,xxx"
" 14. a modifier (format: \"modifier:name,data,string\")\n"
" 15. an info (format: \"info:name,arguments\", arguments are optional)\n"
" 16. a base 16/32/64 encoded/decoded string (format: \"base_encode:base,xxx"
"\" or \"base_decode:base,xxx\")\n"
" 16. current date/time (format: \"date\" or \"date:format\")\n"
" 17. an environment variable (format: \"env:XXX\")\n"
" 18. a ternary operator (format: \"if:condition?value_if_true:value_if_false"
" 17. current date/time (format: \"date\" or \"date:format\")\n"
" 18. an environment variable (format: \"env:XXX\")\n"
" 19. a ternary operator (format: \"if:condition?value_if_true:value_if_false"
"\")\n"
" 19. result of an expression with parentheses and operators + - * / // % ** "
" 20. result of an expression with parentheses and operators + - * / // % ** "
"(format: \"calc:xxx\")\n"
" 20. a random integer number (format: \"random:min,max\")\n"
" 21. a translated string (format: \"translate:xxx\")\n"
" 22. an option (format: \"file.section.option\")\n"
" 23. a local variable in buffer\n"
" 24. a hdata name/variable (the value is automatically converted to "
" 21. a random integer number (format: \"random:min,max\")\n"
" 22. a translated string (format: \"translate:xxx\")\n"
" 23. define a user variable (format: \"define:name,value\")\n"
" 24. an option (format: \"file.section.option\")\n"
" 25. a local variable in buffer\n"
" 26. a hdata name/variable (the value is automatically converted to "
"string), by default \"window\" and \"buffer\" point to current window/"
"buffer.\n"
"Format for hdata can be one of following:\n"
@@ -1724,38 +1726,39 @@ msgid ""
"function \"weechat_hdata_get\".\n"
"\n"
"Examples (simple strings):\n"
" /eval -n ${raw:${info:version}} ==> ${info:version}\n"
" /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
" /eval -n ${info:version} ==> 0.4.3\n"
" /eval -n ${env:HOME} ==> /home/user\n"
" /eval -n ${weechat.look.scroll_amount} ==> 3\n"
" /eval -n ${sec.data.password} ==> secret\n"
" /eval -n ${window} ==> 0x2549aa0\n"
" /eval -n ${window.buffer} ==> 0x2549320\n"
" /eval -n ${window.buffer.full_name} ==> core.weechat\n"
" /eval -n ${window.buffer.number} ==> 1\n"
" /eval -n ${\\t} ==> <tab>\n"
" /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
" /eval -n ${cut:3,+,test} ==> tes+\n"
" /eval -n ${cut:+3,+,test} ==> te+\n"
" /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
" /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
" /eval -n ${rev:Hello} ==> olleH\n"
" /eval -n ${repeat:5,-} ==> -----\n"
" /eval -n ${length:test} ==> 4\n"
" /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
" /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
" /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
" /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
" /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
" /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
" /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${calc:(5+2)*3} ==> 21\n"
" /eval -n ${random:0,10} ==> 3\n"
" /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
" /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
" /eval -n ${translate:Plugin} ==> Extension\n"
" /eval -n ${raw:${info:version}} ==> ${info:version}\n"
" /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
" /eval -n ${info:version} ==> 0.4.3\n"
" /eval -n ${env:HOME} ==> /home/user\n"
" /eval -n ${weechat.look.scroll_amount} ==> 3\n"
" /eval -n ${sec.data.password} ==> secret\n"
" /eval -n ${window} ==> 0x2549aa0\n"
" /eval -n ${window.buffer} ==> 0x2549320\n"
" /eval -n ${window.buffer.full_name} ==> core.weechat\n"
" /eval -n ${window.buffer.number} ==> 1\n"
" /eval -n ${\\t} ==> <tab>\n"
" /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
" /eval -n ${cut:3,+,test} ==> tes+\n"
" /eval -n ${cut:+3,+,test} ==> te+\n"
" /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
" /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
" /eval -n ${rev:Hello} ==> olleH\n"
" /eval -n ${repeat:5,-} ==> -----\n"
" /eval -n ${length:test} ==> 4\n"
" /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
" /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
" /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
" /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
" /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
" /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
" /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${calc:(5+2)*3} ==> 21\n"
" /eval -n ${random:0,10} ==> 3\n"
" /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
" /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
" /eval -n ${translate:Plugin} ==> Extension\n"
" /eval -n ${define:len,${calc:5+3}}${len}x${len} ==> 8x8\n"
"\n"
"Examples (conditions):\n"
" /eval -n -c ${window.buffer.number} > 2 ==> 0\n"
+59 -56
View File
@@ -21,7 +21,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2021-09-09 21:07+0200\n"
"POT-Creation-Date: 2021-09-20 21:12+0200\n"
"PO-Revision-Date: 2021-07-10 16:01+0200\n"
"Last-Translator: Aleksey V Zapparov AKA ixti <ixti@member.fsf.org>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@@ -1536,36 +1536,38 @@ msgid ""
"Some variables are replaced in expression, using the format ${variable}, "
"variable can be, by order of priority:\n"
" 1. the string itself without evaluation (format: \"raw:xxx\")\n"
" 2. an evaluated sub-string (format: \"eval:xxx\")\n"
" 3. an evaluated condition (format: \"eval_cond:xxx\")\n"
" 4. a string with escaped chars (format: \"esc:xxx\" or \"\\xxx\")\n"
" 5. a string with chars to hide (format: \"hide:char,string\")\n"
" 6. a string with max chars (format: \"cut:max,suffix,string\" or \"cut:"
" 2. a user-defined variable (format: \"name\")\n"
" 3. an evaluated sub-string (format: \"eval:xxx\")\n"
" 4. an evaluated condition (format: \"eval_cond:xxx\")\n"
" 5. a string with escaped chars (format: \"esc:xxx\" or \"\\xxx\")\n"
" 6. a string with chars to hide (format: \"hide:char,string\")\n"
" 7. a string with max chars (format: \"cut:max,suffix,string\" or \"cut:"
"+max,suffix,string\")\n"
" or max chars displayed on screen (format: \"cutscr:max,suffix,string\" "
"or \"cutscr:+max,suffix,string\")\n"
" 7. a reversed string (format: \"rev:xxx\" or \"revscr:xxx\")\n"
" 8. a repeated string (format: \"repeat:count,string\")\n"
" 9. length of a string (format: \"length:xxx\" or \"lengthscr:xxx\")\n"
" 10. split of a string (format: \"split:number,separators,flags,xxx\")\n"
" 11. split of shell argmuents (format: \"split_shell:number,xxx\")\n"
" 12. a color (format: \"color:xxx\", see \"Plugin API reference\", function "
" 8. a reversed string (format: \"rev:xxx\" or \"revscr:xxx\")\n"
" 9. a repeated string (format: \"repeat:count,string\")\n"
" 10. length of a string (format: \"length:xxx\" or \"lengthscr:xxx\")\n"
" 11. split of a string (format: \"split:number,separators,flags,xxx\")\n"
" 12. split of shell argmuents (format: \"split_shell:number,xxx\")\n"
" 13. a color (format: \"color:xxx\", see \"Plugin API reference\", function "
"\"color\")\n"
" 13. a modifier (format: \"modifier:name,data,string\")\n"
" 14. an info (format: \"info:name,arguments\", arguments are optional)\n"
" 15. a base 16/32/64 encoded/decoded string (format: \"base_encode:base,xxx"
" 14. a modifier (format: \"modifier:name,data,string\")\n"
" 15. an info (format: \"info:name,arguments\", arguments are optional)\n"
" 16. a base 16/32/64 encoded/decoded string (format: \"base_encode:base,xxx"
"\" or \"base_decode:base,xxx\")\n"
" 16. current date/time (format: \"date\" or \"date:format\")\n"
" 17. an environment variable (format: \"env:XXX\")\n"
" 18. a ternary operator (format: \"if:condition?value_if_true:value_if_false"
" 17. current date/time (format: \"date\" or \"date:format\")\n"
" 18. an environment variable (format: \"env:XXX\")\n"
" 19. a ternary operator (format: \"if:condition?value_if_true:value_if_false"
"\")\n"
" 19. result of an expression with parentheses and operators + - * / // % ** "
" 20. result of an expression with parentheses and operators + - * / // % ** "
"(format: \"calc:xxx\")\n"
" 20. a random integer number (format: \"random:min,max\")\n"
" 21. a translated string (format: \"translate:xxx\")\n"
" 22. an option (format: \"file.section.option\")\n"
" 23. a local variable in buffer\n"
" 24. a hdata name/variable (the value is automatically converted to "
" 21. a random integer number (format: \"random:min,max\")\n"
" 22. a translated string (format: \"translate:xxx\")\n"
" 23. define a user variable (format: \"define:name,value\")\n"
" 24. an option (format: \"file.section.option\")\n"
" 25. a local variable in buffer\n"
" 26. a hdata name/variable (the value is automatically converted to "
"string), by default \"window\" and \"buffer\" point to current window/"
"buffer.\n"
"Format for hdata can be one of following:\n"
@@ -1587,38 +1589,39 @@ msgid ""
"function \"weechat_hdata_get\".\n"
"\n"
"Examples (simple strings):\n"
" /eval -n ${raw:${info:version}} ==> ${info:version}\n"
" /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
" /eval -n ${info:version} ==> 0.4.3\n"
" /eval -n ${env:HOME} ==> /home/user\n"
" /eval -n ${weechat.look.scroll_amount} ==> 3\n"
" /eval -n ${sec.data.password} ==> secret\n"
" /eval -n ${window} ==> 0x2549aa0\n"
" /eval -n ${window.buffer} ==> 0x2549320\n"
" /eval -n ${window.buffer.full_name} ==> core.weechat\n"
" /eval -n ${window.buffer.number} ==> 1\n"
" /eval -n ${\\t} ==> <tab>\n"
" /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
" /eval -n ${cut:3,+,test} ==> tes+\n"
" /eval -n ${cut:+3,+,test} ==> te+\n"
" /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
" /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
" /eval -n ${rev:Hello} ==> olleH\n"
" /eval -n ${repeat:5,-} ==> -----\n"
" /eval -n ${length:test} ==> 4\n"
" /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
" /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
" /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
" /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
" /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
" /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
" /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${calc:(5+2)*3} ==> 21\n"
" /eval -n ${random:0,10} ==> 3\n"
" /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
" /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
" /eval -n ${translate:Plugin} ==> Extension\n"
" /eval -n ${raw:${info:version}} ==> ${info:version}\n"
" /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
" /eval -n ${info:version} ==> 0.4.3\n"
" /eval -n ${env:HOME} ==> /home/user\n"
" /eval -n ${weechat.look.scroll_amount} ==> 3\n"
" /eval -n ${sec.data.password} ==> secret\n"
" /eval -n ${window} ==> 0x2549aa0\n"
" /eval -n ${window.buffer} ==> 0x2549320\n"
" /eval -n ${window.buffer.full_name} ==> core.weechat\n"
" /eval -n ${window.buffer.number} ==> 1\n"
" /eval -n ${\\t} ==> <tab>\n"
" /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
" /eval -n ${cut:3,+,test} ==> tes+\n"
" /eval -n ${cut:+3,+,test} ==> te+\n"
" /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
" /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
" /eval -n ${rev:Hello} ==> olleH\n"
" /eval -n ${repeat:5,-} ==> -----\n"
" /eval -n ${length:test} ==> 4\n"
" /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
" /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
" /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
" /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
" /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
" /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
" /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${calc:(5+2)*3} ==> 21\n"
" /eval -n ${random:0,10} ==> 3\n"
" /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
" /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
" /eval -n ${translate:Plugin} ==> Extension\n"
" /eval -n ${define:len,${calc:5+3}}${len}x${len} ==> 8x8\n"
"\n"
"Examples (conditions):\n"
" /eval -n -c ${window.buffer.number} > 2 ==> 0\n"
+59 -56
View File
@@ -20,7 +20,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2021-09-09 21:07+0200\n"
"POT-Creation-Date: 2021-09-20 21:12+0200\n"
"PO-Revision-Date: 2021-09-01 02:38+0400\n"
"Last-Translator: Ivan Pešić <ivan.pesic@gmail.com>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@@ -1831,36 +1831,38 @@ msgid ""
"Some variables are replaced in expression, using the format ${variable}, "
"variable can be, by order of priority:\n"
" 1. the string itself without evaluation (format: \"raw:xxx\")\n"
" 2. an evaluated sub-string (format: \"eval:xxx\")\n"
" 3. an evaluated condition (format: \"eval_cond:xxx\")\n"
" 4. a string with escaped chars (format: \"esc:xxx\" or \"\\xxx\")\n"
" 5. a string with chars to hide (format: \"hide:char,string\")\n"
" 6. a string with max chars (format: \"cut:max,suffix,string\" or \"cut:"
" 2. a user-defined variable (format: \"name\")\n"
" 3. an evaluated sub-string (format: \"eval:xxx\")\n"
" 4. an evaluated condition (format: \"eval_cond:xxx\")\n"
" 5. a string with escaped chars (format: \"esc:xxx\" or \"\\xxx\")\n"
" 6. a string with chars to hide (format: \"hide:char,string\")\n"
" 7. a string with max chars (format: \"cut:max,suffix,string\" or \"cut:"
"+max,suffix,string\")\n"
" or max chars displayed on screen (format: \"cutscr:max,suffix,string\" "
"or \"cutscr:+max,suffix,string\")\n"
" 7. a reversed string (format: \"rev:xxx\" or \"revscr:xxx\")\n"
" 8. a repeated string (format: \"repeat:count,string\")\n"
" 9. length of a string (format: \"length:xxx\" or \"lengthscr:xxx\")\n"
" 10. split of a string (format: \"split:number,separators,flags,xxx\")\n"
" 11. split of shell argmuents (format: \"split_shell:number,xxx\")\n"
" 12. a color (format: \"color:xxx\", see \"Plugin API reference\", function "
" 8. a reversed string (format: \"rev:xxx\" or \"revscr:xxx\")\n"
" 9. a repeated string (format: \"repeat:count,string\")\n"
" 10. length of a string (format: \"length:xxx\" or \"lengthscr:xxx\")\n"
" 11. split of a string (format: \"split:number,separators,flags,xxx\")\n"
" 12. split of shell argmuents (format: \"split_shell:number,xxx\")\n"
" 13. a color (format: \"color:xxx\", see \"Plugin API reference\", function "
"\"color\")\n"
" 13. a modifier (format: \"modifier:name,data,string\")\n"
" 14. an info (format: \"info:name,arguments\", arguments are optional)\n"
" 15. a base 16/32/64 encoded/decoded string (format: \"base_encode:base,xxx"
" 14. a modifier (format: \"modifier:name,data,string\")\n"
" 15. an info (format: \"info:name,arguments\", arguments are optional)\n"
" 16. a base 16/32/64 encoded/decoded string (format: \"base_encode:base,xxx"
"\" or \"base_decode:base,xxx\")\n"
" 16. current date/time (format: \"date\" or \"date:format\")\n"
" 17. an environment variable (format: \"env:XXX\")\n"
" 18. a ternary operator (format: \"if:condition?value_if_true:value_if_false"
" 17. current date/time (format: \"date\" or \"date:format\")\n"
" 18. an environment variable (format: \"env:XXX\")\n"
" 19. a ternary operator (format: \"if:condition?value_if_true:value_if_false"
"\")\n"
" 19. result of an expression with parentheses and operators + - * / // % ** "
" 20. result of an expression with parentheses and operators + - * / // % ** "
"(format: \"calc:xxx\")\n"
" 20. a random integer number (format: \"random:min,max\")\n"
" 21. a translated string (format: \"translate:xxx\")\n"
" 22. an option (format: \"file.section.option\")\n"
" 23. a local variable in buffer\n"
" 24. a hdata name/variable (the value is automatically converted to "
" 21. a random integer number (format: \"random:min,max\")\n"
" 22. a translated string (format: \"translate:xxx\")\n"
" 23. define a user variable (format: \"define:name,value\")\n"
" 24. an option (format: \"file.section.option\")\n"
" 25. a local variable in buffer\n"
" 26. a hdata name/variable (the value is automatically converted to "
"string), by default \"window\" and \"buffer\" point to current window/"
"buffer.\n"
"Format for hdata can be one of following:\n"
@@ -1882,38 +1884,39 @@ msgid ""
"function \"weechat_hdata_get\".\n"
"\n"
"Examples (simple strings):\n"
" /eval -n ${raw:${info:version}} ==> ${info:version}\n"
" /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
" /eval -n ${info:version} ==> 0.4.3\n"
" /eval -n ${env:HOME} ==> /home/user\n"
" /eval -n ${weechat.look.scroll_amount} ==> 3\n"
" /eval -n ${sec.data.password} ==> secret\n"
" /eval -n ${window} ==> 0x2549aa0\n"
" /eval -n ${window.buffer} ==> 0x2549320\n"
" /eval -n ${window.buffer.full_name} ==> core.weechat\n"
" /eval -n ${window.buffer.number} ==> 1\n"
" /eval -n ${\\t} ==> <tab>\n"
" /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
" /eval -n ${cut:3,+,test} ==> tes+\n"
" /eval -n ${cut:+3,+,test} ==> te+\n"
" /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
" /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
" /eval -n ${rev:Hello} ==> olleH\n"
" /eval -n ${repeat:5,-} ==> -----\n"
" /eval -n ${length:test} ==> 4\n"
" /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
" /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
" /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
" /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
" /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
" /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
" /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${calc:(5+2)*3} ==> 21\n"
" /eval -n ${random:0,10} ==> 3\n"
" /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
" /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
" /eval -n ${translate:Plugin} ==> Extension\n"
" /eval -n ${raw:${info:version}} ==> ${info:version}\n"
" /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
" /eval -n ${info:version} ==> 0.4.3\n"
" /eval -n ${env:HOME} ==> /home/user\n"
" /eval -n ${weechat.look.scroll_amount} ==> 3\n"
" /eval -n ${sec.data.password} ==> secret\n"
" /eval -n ${window} ==> 0x2549aa0\n"
" /eval -n ${window.buffer} ==> 0x2549320\n"
" /eval -n ${window.buffer.full_name} ==> core.weechat\n"
" /eval -n ${window.buffer.number} ==> 1\n"
" /eval -n ${\\t} ==> <tab>\n"
" /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
" /eval -n ${cut:3,+,test} ==> tes+\n"
" /eval -n ${cut:+3,+,test} ==> te+\n"
" /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
" /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
" /eval -n ${rev:Hello} ==> olleH\n"
" /eval -n ${repeat:5,-} ==> -----\n"
" /eval -n ${length:test} ==> 4\n"
" /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
" /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
" /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
" /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
" /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
" /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
" /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${calc:(5+2)*3} ==> 21\n"
" /eval -n ${random:0,10} ==> 3\n"
" /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
" /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
" /eval -n ${translate:Plugin} ==> Extension\n"
" /eval -n ${define:len,${calc:5+3}}${len}x${len} ==> 8x8\n"
"\n"
"Examples (conditions):\n"
" /eval -n -c ${window.buffer.number} > 2 ==> 0\n"
+59 -56
View File
@@ -20,7 +20,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2021-09-09 21:07+0200\n"
"POT-Creation-Date: 2021-09-20 21:12+0200\n"
"PO-Revision-Date: 2021-07-10 16:01+0200\n"
"Last-Translator: Emir SARI <bitigchi@me.com>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@@ -1683,36 +1683,38 @@ msgid ""
"Some variables are replaced in expression, using the format ${variable}, "
"variable can be, by order of priority:\n"
" 1. the string itself without evaluation (format: \"raw:xxx\")\n"
" 2. an evaluated sub-string (format: \"eval:xxx\")\n"
" 3. an evaluated condition (format: \"eval_cond:xxx\")\n"
" 4. a string with escaped chars (format: \"esc:xxx\" or \"\\xxx\")\n"
" 5. a string with chars to hide (format: \"hide:char,string\")\n"
" 6. a string with max chars (format: \"cut:max,suffix,string\" or \"cut:"
" 2. a user-defined variable (format: \"name\")\n"
" 3. an evaluated sub-string (format: \"eval:xxx\")\n"
" 4. an evaluated condition (format: \"eval_cond:xxx\")\n"
" 5. a string with escaped chars (format: \"esc:xxx\" or \"\\xxx\")\n"
" 6. a string with chars to hide (format: \"hide:char,string\")\n"
" 7. a string with max chars (format: \"cut:max,suffix,string\" or \"cut:"
"+max,suffix,string\")\n"
" or max chars displayed on screen (format: \"cutscr:max,suffix,string\" "
"or \"cutscr:+max,suffix,string\")\n"
" 7. a reversed string (format: \"rev:xxx\" or \"revscr:xxx\")\n"
" 8. a repeated string (format: \"repeat:count,string\")\n"
" 9. length of a string (format: \"length:xxx\" or \"lengthscr:xxx\")\n"
" 10. split of a string (format: \"split:number,separators,flags,xxx\")\n"
" 11. split of shell argmuents (format: \"split_shell:number,xxx\")\n"
" 12. a color (format: \"color:xxx\", see \"Plugin API reference\", function "
" 8. a reversed string (format: \"rev:xxx\" or \"revscr:xxx\")\n"
" 9. a repeated string (format: \"repeat:count,string\")\n"
" 10. length of a string (format: \"length:xxx\" or \"lengthscr:xxx\")\n"
" 11. split of a string (format: \"split:number,separators,flags,xxx\")\n"
" 12. split of shell argmuents (format: \"split_shell:number,xxx\")\n"
" 13. a color (format: \"color:xxx\", see \"Plugin API reference\", function "
"\"color\")\n"
" 13. a modifier (format: \"modifier:name,data,string\")\n"
" 14. an info (format: \"info:name,arguments\", arguments are optional)\n"
" 15. a base 16/32/64 encoded/decoded string (format: \"base_encode:base,xxx"
" 14. a modifier (format: \"modifier:name,data,string\")\n"
" 15. an info (format: \"info:name,arguments\", arguments are optional)\n"
" 16. a base 16/32/64 encoded/decoded string (format: \"base_encode:base,xxx"
"\" or \"base_decode:base,xxx\")\n"
" 16. current date/time (format: \"date\" or \"date:format\")\n"
" 17. an environment variable (format: \"env:XXX\")\n"
" 18. a ternary operator (format: \"if:condition?value_if_true:value_if_false"
" 17. current date/time (format: \"date\" or \"date:format\")\n"
" 18. an environment variable (format: \"env:XXX\")\n"
" 19. a ternary operator (format: \"if:condition?value_if_true:value_if_false"
"\")\n"
" 19. result of an expression with parentheses and operators + - * / // % ** "
" 20. result of an expression with parentheses and operators + - * / // % ** "
"(format: \"calc:xxx\")\n"
" 20. a random integer number (format: \"random:min,max\")\n"
" 21. a translated string (format: \"translate:xxx\")\n"
" 22. an option (format: \"file.section.option\")\n"
" 23. a local variable in buffer\n"
" 24. a hdata name/variable (the value is automatically converted to "
" 21. a random integer number (format: \"random:min,max\")\n"
" 22. a translated string (format: \"translate:xxx\")\n"
" 23. define a user variable (format: \"define:name,value\")\n"
" 24. an option (format: \"file.section.option\")\n"
" 25. a local variable in buffer\n"
" 26. a hdata name/variable (the value is automatically converted to "
"string), by default \"window\" and \"buffer\" point to current window/"
"buffer.\n"
"Format for hdata can be one of following:\n"
@@ -1734,38 +1736,39 @@ msgid ""
"function \"weechat_hdata_get\".\n"
"\n"
"Examples (simple strings):\n"
" /eval -n ${raw:${info:version}} ==> ${info:version}\n"
" /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
" /eval -n ${info:version} ==> 0.4.3\n"
" /eval -n ${env:HOME} ==> /home/user\n"
" /eval -n ${weechat.look.scroll_amount} ==> 3\n"
" /eval -n ${sec.data.password} ==> secret\n"
" /eval -n ${window} ==> 0x2549aa0\n"
" /eval -n ${window.buffer} ==> 0x2549320\n"
" /eval -n ${window.buffer.full_name} ==> core.weechat\n"
" /eval -n ${window.buffer.number} ==> 1\n"
" /eval -n ${\\t} ==> <tab>\n"
" /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
" /eval -n ${cut:3,+,test} ==> tes+\n"
" /eval -n ${cut:+3,+,test} ==> te+\n"
" /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
" /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
" /eval -n ${rev:Hello} ==> olleH\n"
" /eval -n ${repeat:5,-} ==> -----\n"
" /eval -n ${length:test} ==> 4\n"
" /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
" /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
" /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
" /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
" /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
" /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
" /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${calc:(5+2)*3} ==> 21\n"
" /eval -n ${random:0,10} ==> 3\n"
" /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
" /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
" /eval -n ${translate:Plugin} ==> Extension\n"
" /eval -n ${raw:${info:version}} ==> ${info:version}\n"
" /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
" /eval -n ${info:version} ==> 0.4.3\n"
" /eval -n ${env:HOME} ==> /home/user\n"
" /eval -n ${weechat.look.scroll_amount} ==> 3\n"
" /eval -n ${sec.data.password} ==> secret\n"
" /eval -n ${window} ==> 0x2549aa0\n"
" /eval -n ${window.buffer} ==> 0x2549320\n"
" /eval -n ${window.buffer.full_name} ==> core.weechat\n"
" /eval -n ${window.buffer.number} ==> 1\n"
" /eval -n ${\\t} ==> <tab>\n"
" /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
" /eval -n ${cut:3,+,test} ==> tes+\n"
" /eval -n ${cut:+3,+,test} ==> te+\n"
" /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
" /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
" /eval -n ${rev:Hello} ==> olleH\n"
" /eval -n ${repeat:5,-} ==> -----\n"
" /eval -n ${length:test} ==> 4\n"
" /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
" /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
" /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
" /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
" /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
" /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
" /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${calc:(5+2)*3} ==> 21\n"
" /eval -n ${random:0,10} ==> 3\n"
" /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
" /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
" /eval -n ${translate:Plugin} ==> Extension\n"
" /eval -n ${define:len,${calc:5+3}}${len}x${len} ==> 8x8\n"
"\n"
"Examples (conditions):\n"
" /eval -n -c ${window.buffer.number} > 2 ==> 0\n"
+59 -56
View File
@@ -21,7 +21,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2021-09-09 21:07+0200\n"
"POT-Creation-Date: 2021-09-20 21:12+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"
@@ -1369,36 +1369,38 @@ msgid ""
"Some variables are replaced in expression, using the format ${variable}, "
"variable can be, by order of priority:\n"
" 1. the string itself without evaluation (format: \"raw:xxx\")\n"
" 2. an evaluated sub-string (format: \"eval:xxx\")\n"
" 3. an evaluated condition (format: \"eval_cond:xxx\")\n"
" 4. a string with escaped chars (format: \"esc:xxx\" or \"\\xxx\")\n"
" 5. a string with chars to hide (format: \"hide:char,string\")\n"
" 6. a string with max chars (format: \"cut:max,suffix,string\" or \"cut:"
" 2. a user-defined variable (format: \"name\")\n"
" 3. an evaluated sub-string (format: \"eval:xxx\")\n"
" 4. an evaluated condition (format: \"eval_cond:xxx\")\n"
" 5. a string with escaped chars (format: \"esc:xxx\" or \"\\xxx\")\n"
" 6. a string with chars to hide (format: \"hide:char,string\")\n"
" 7. a string with max chars (format: \"cut:max,suffix,string\" or \"cut:"
"+max,suffix,string\")\n"
" or max chars displayed on screen (format: \"cutscr:max,suffix,string\" "
"or \"cutscr:+max,suffix,string\")\n"
" 7. a reversed string (format: \"rev:xxx\" or \"revscr:xxx\")\n"
" 8. a repeated string (format: \"repeat:count,string\")\n"
" 9. length of a string (format: \"length:xxx\" or \"lengthscr:xxx\")\n"
" 10. split of a string (format: \"split:number,separators,flags,xxx\")\n"
" 11. split of shell argmuents (format: \"split_shell:number,xxx\")\n"
" 12. a color (format: \"color:xxx\", see \"Plugin API reference\", function "
" 8. a reversed string (format: \"rev:xxx\" or \"revscr:xxx\")\n"
" 9. a repeated string (format: \"repeat:count,string\")\n"
" 10. length of a string (format: \"length:xxx\" or \"lengthscr:xxx\")\n"
" 11. split of a string (format: \"split:number,separators,flags,xxx\")\n"
" 12. split of shell argmuents (format: \"split_shell:number,xxx\")\n"
" 13. a color (format: \"color:xxx\", see \"Plugin API reference\", function "
"\"color\")\n"
" 13. a modifier (format: \"modifier:name,data,string\")\n"
" 14. an info (format: \"info:name,arguments\", arguments are optional)\n"
" 15. a base 16/32/64 encoded/decoded string (format: \"base_encode:base,xxx"
" 14. a modifier (format: \"modifier:name,data,string\")\n"
" 15. an info (format: \"info:name,arguments\", arguments are optional)\n"
" 16. a base 16/32/64 encoded/decoded string (format: \"base_encode:base,xxx"
"\" or \"base_decode:base,xxx\")\n"
" 16. current date/time (format: \"date\" or \"date:format\")\n"
" 17. an environment variable (format: \"env:XXX\")\n"
" 18. a ternary operator (format: \"if:condition?value_if_true:value_if_false"
" 17. current date/time (format: \"date\" or \"date:format\")\n"
" 18. an environment variable (format: \"env:XXX\")\n"
" 19. a ternary operator (format: \"if:condition?value_if_true:value_if_false"
"\")\n"
" 19. result of an expression with parentheses and operators + - * / // % ** "
" 20. result of an expression with parentheses and operators + - * / // % ** "
"(format: \"calc:xxx\")\n"
" 20. a random integer number (format: \"random:min,max\")\n"
" 21. a translated string (format: \"translate:xxx\")\n"
" 22. an option (format: \"file.section.option\")\n"
" 23. a local variable in buffer\n"
" 24. a hdata name/variable (the value is automatically converted to "
" 21. a random integer number (format: \"random:min,max\")\n"
" 22. a translated string (format: \"translate:xxx\")\n"
" 23. define a user variable (format: \"define:name,value\")\n"
" 24. an option (format: \"file.section.option\")\n"
" 25. a local variable in buffer\n"
" 26. a hdata name/variable (the value is automatically converted to "
"string), by default \"window\" and \"buffer\" point to current window/"
"buffer.\n"
"Format for hdata can be one of following:\n"
@@ -1420,38 +1422,39 @@ msgid ""
"function \"weechat_hdata_get\".\n"
"\n"
"Examples (simple strings):\n"
" /eval -n ${raw:${info:version}} ==> ${info:version}\n"
" /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
" /eval -n ${info:version} ==> 0.4.3\n"
" /eval -n ${env:HOME} ==> /home/user\n"
" /eval -n ${weechat.look.scroll_amount} ==> 3\n"
" /eval -n ${sec.data.password} ==> secret\n"
" /eval -n ${window} ==> 0x2549aa0\n"
" /eval -n ${window.buffer} ==> 0x2549320\n"
" /eval -n ${window.buffer.full_name} ==> core.weechat\n"
" /eval -n ${window.buffer.number} ==> 1\n"
" /eval -n ${\\t} ==> <tab>\n"
" /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
" /eval -n ${cut:3,+,test} ==> tes+\n"
" /eval -n ${cut:+3,+,test} ==> te+\n"
" /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
" /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
" /eval -n ${rev:Hello} ==> olleH\n"
" /eval -n ${repeat:5,-} ==> -----\n"
" /eval -n ${length:test} ==> 4\n"
" /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
" /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
" /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
" /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
" /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
" /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
" /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${calc:(5+2)*3} ==> 21\n"
" /eval -n ${random:0,10} ==> 3\n"
" /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
" /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
" /eval -n ${translate:Plugin} ==> Extension\n"
" /eval -n ${raw:${info:version}} ==> ${info:version}\n"
" /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
" /eval -n ${info:version} ==> 0.4.3\n"
" /eval -n ${env:HOME} ==> /home/user\n"
" /eval -n ${weechat.look.scroll_amount} ==> 3\n"
" /eval -n ${sec.data.password} ==> secret\n"
" /eval -n ${window} ==> 0x2549aa0\n"
" /eval -n ${window.buffer} ==> 0x2549320\n"
" /eval -n ${window.buffer.full_name} ==> core.weechat\n"
" /eval -n ${window.buffer.number} ==> 1\n"
" /eval -n ${\\t} ==> <tab>\n"
" /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
" /eval -n ${cut:3,+,test} ==> tes+\n"
" /eval -n ${cut:+3,+,test} ==> te+\n"
" /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
" /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
" /eval -n ${rev:Hello} ==> olleH\n"
" /eval -n ${repeat:5,-} ==> -----\n"
" /eval -n ${length:test} ==> 4\n"
" /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
" /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
" /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
" /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
" /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
" /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
" /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${calc:(5+2)*3} ==> 21\n"
" /eval -n ${random:0,10} ==> 3\n"
" /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
" /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
" /eval -n ${translate:Plugin} ==> Extension\n"
" /eval -n ${define:len,${calc:5+3}}${len}x${len} ==> 8x8\n"
"\n"
"Examples (conditions):\n"
" /eval -n -c ${window.buffer.number} > 2 ==> 0\n"
+58 -55
View File
@@ -7658,40 +7658,42 @@ command_init ()
"Some variables are replaced in expression, using the format "
"${variable}, variable can be, by order of priority:\n"
" 1. the string itself without evaluation (format: \"raw:xxx\")\n"
" 2. an evaluated sub-string (format: \"eval:xxx\")\n"
" 3. an evaluated condition (format: \"eval_cond:xxx\")\n"
" 4. a string with escaped chars (format: \"esc:xxx\" or \"\\xxx\")\n"
" 5. a string with chars to hide (format: \"hide:char,string\")\n"
" 6. a string with max chars (format: \"cut:max,suffix,string\" "
" 2. a user-defined variable (format: \"name\")\n"
" 3. an evaluated sub-string (format: \"eval:xxx\")\n"
" 4. an evaluated condition (format: \"eval_cond:xxx\")\n"
" 5. a string with escaped chars (format: \"esc:xxx\" or \"\\xxx\")\n"
" 6. a string with chars to hide (format: \"hide:char,string\")\n"
" 7. a string with max chars (format: \"cut:max,suffix,string\" "
"or \"cut:+max,suffix,string\")\n"
" or max chars displayed on screen "
"(format: \"cutscr:max,suffix,string\" or "
"\"cutscr:+max,suffix,string\")\n"
" 7. a reversed string (format: \"rev:xxx\" or \"revscr:xxx\")\n"
" 8. a repeated string (format: \"repeat:count,string\")\n"
" 9. length of a string (format: \"length:xxx\" or "
" 8. a reversed string (format: \"rev:xxx\" or \"revscr:xxx\")\n"
" 9. a repeated string (format: \"repeat:count,string\")\n"
" 10. length of a string (format: \"length:xxx\" or "
"\"lengthscr:xxx\")\n"
" 10. split of a string (format: "
" 11. split of a string (format: "
"\"split:number,separators,flags,xxx\")\n"
" 11. split of shell argmuents (format: \"split_shell:number,xxx\")\n"
" 12. a color (format: \"color:xxx\", see \"Plugin API "
" 12. split of shell argmuents (format: \"split_shell:number,xxx\")\n"
" 13. a color (format: \"color:xxx\", see \"Plugin API "
"reference\", function \"color\")\n"
" 13. a modifier (format: \"modifier:name,data,string\")\n"
" 14. an info (format: \"info:name,arguments\", arguments are "
" 14. a modifier (format: \"modifier:name,data,string\")\n"
" 15. an info (format: \"info:name,arguments\", arguments are "
"optional)\n"
" 15. a base 16/32/64 encoded/decoded string (format: "
" 16. a base 16/32/64 encoded/decoded string (format: "
"\"base_encode:base,xxx\" or \"base_decode:base,xxx\")\n"
" 16. current date/time (format: \"date\" or \"date:format\")\n"
" 17. an environment variable (format: \"env:XXX\")\n"
" 18. a ternary operator (format: "
" 17. current date/time (format: \"date\" or \"date:format\")\n"
" 18. an environment variable (format: \"env:XXX\")\n"
" 19. a ternary operator (format: "
"\"if:condition?value_if_true:value_if_false\")\n"
" 19. result of an expression with parentheses and operators "
" 20. result of an expression with parentheses and operators "
"+ - * / // % ** (format: \"calc:xxx\")\n"
" 20. a random integer number (format: \"random:min,max\")\n"
" 21. a translated string (format: \"translate:xxx\")\n"
" 22. an option (format: \"file.section.option\")\n"
" 23. a local variable in buffer\n"
" 24. a hdata name/variable (the value is automatically converted "
" 21. a random integer number (format: \"random:min,max\")\n"
" 22. a translated string (format: \"translate:xxx\")\n"
" 23. define a user variable (format: \"define:name,value\")\n"
" 24. an option (format: \"file.section.option\")\n"
" 25. a local variable in buffer\n"
" 26. a hdata name/variable (the value is automatically converted "
"to string), by default \"window\" and \"buffer\" point to current "
"window/buffer.\n"
"Format for hdata can be one of following:\n"
@@ -7713,38 +7715,39 @@ command_init ()
"reference\", function \"weechat_hdata_get\".\n"
"\n"
"Examples (simple strings):\n"
" /eval -n ${raw:${info:version}} ==> ${info:version}\n"
" /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
" /eval -n ${info:version} ==> 0.4.3\n"
" /eval -n ${env:HOME} ==> /home/user\n"
" /eval -n ${weechat.look.scroll_amount} ==> 3\n"
" /eval -n ${sec.data.password} ==> secret\n"
" /eval -n ${window} ==> 0x2549aa0\n"
" /eval -n ${window.buffer} ==> 0x2549320\n"
" /eval -n ${window.buffer.full_name} ==> core.weechat\n"
" /eval -n ${window.buffer.number} ==> 1\n"
" /eval -n ${\\t} ==> <tab>\n"
" /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
" /eval -n ${cut:3,+,test} ==> tes+\n"
" /eval -n ${cut:+3,+,test} ==> te+\n"
" /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
" /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
" /eval -n ${rev:Hello} ==> olleH\n"
" /eval -n ${repeat:5,-} ==> -----\n"
" /eval -n ${length:test} ==> 4\n"
" /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
" /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
" /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
" /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
" /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
" /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
" /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${calc:(5+2)*3} ==> 21\n"
" /eval -n ${random:0,10} ==> 3\n"
" /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
" /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
" /eval -n ${translate:Plugin} ==> Extension\n"
" /eval -n ${raw:${info:version}} ==> ${info:version}\n"
" /eval -n ${eval_cond:${window.win_width}>100} ==> 1\n"
" /eval -n ${info:version} ==> 0.4.3\n"
" /eval -n ${env:HOME} ==> /home/user\n"
" /eval -n ${weechat.look.scroll_amount} ==> 3\n"
" /eval -n ${sec.data.password} ==> secret\n"
" /eval -n ${window} ==> 0x2549aa0\n"
" /eval -n ${window.buffer} ==> 0x2549320\n"
" /eval -n ${window.buffer.full_name} ==> core.weechat\n"
" /eval -n ${window.buffer.number} ==> 1\n"
" /eval -n ${\\t} ==> <tab>\n"
" /eval -n ${hide:-,${relay.network.password}} ==> --------\n"
" /eval -n ${cut:3,+,test} ==> tes+\n"
" /eval -n ${cut:+3,+,test} ==> te+\n"
" /eval -n ${date:%H:%M:%S} ==> 07:46:40\n"
" /eval -n ${if:${info:term_width}>80?big:small} ==> big\n"
" /eval -n ${rev:Hello} ==> olleH\n"
" /eval -n ${repeat:5,-} ==> -----\n"
" /eval -n ${length:test} ==> 4\n"
" /eval -n ${split:1,,,abc,def,ghi} ==> abc\n"
" /eval -n ${split:-1,,,abc,def,ghi} ==> ghi\n"
" /eval -n ${split:count,,,abc,def,ghi} ==> 3\n"
" /eval -n ${split:random,,,abc,def,ghi} ==> def\n"
" /eval -n ${split_shell:1,\"arg 1\" arg2} ==> arg 1\n"
" /eval -n ${split_shell:-1,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${split_shell:count,\"arg 1\" arg2} ==> 2\n"
" /eval -n ${split_shell:random,\"arg 1\" arg2} ==> arg2\n"
" /eval -n ${calc:(5+2)*3} ==> 21\n"
" /eval -n ${random:0,10} ==> 3\n"
" /eval -n ${base_encode:64,test} ==> dGVzdA==\n"
" /eval -n ${base_decode:64,dGVzdA==} ==> test\n"
" /eval -n ${translate:Plugin} ==> Extension\n"
" /eval -n ${define:len,${calc:5+3}}${len}x${len} ==> 8x8\n"
"\n"
"Examples (conditions):\n"
" /eval -n -c ${window.buffer.number} > 2 ==> 0\n"
+49 -2
View File
@@ -1068,6 +1068,28 @@ eval_string_translate (const char *text)
return strdup ((ptr_string) ? ptr_string : "");
}
/*
* Defines a variable.
*/
void
eval_string_define (const char *text, struct t_eval_context *eval_context)
{
char *pos, *name;
pos = strchr (text, ',');
if (!pos)
return;
name = strndup (text, pos - text);
if (!name)
return;
hashtable_set (eval_context->user_vars, name, pos + 1);
free (name);
}
/*
* Gets value of hdata using "path" to a variable.
*
@@ -1352,7 +1374,7 @@ end:
/*
* Replaces variables, which can be, by order of priority:
* 1. the string itself without evaluation (format: raw:xxx)
* 2. an extra variable from hashtable "extra_vars"
* 2. a variable from hashtable "user_vars" or "extra_vars"
* 3. a WeeChat home directory, one of: "weechat_config_dir",
* "weechat_data_dir", "weechat_cache_dir", "weechat_runtime_dir"
* 4. a string to evaluate (format: eval:xxx)
@@ -1421,7 +1443,13 @@ eval_replace_vars_cb (void *data, const char *text)
goto end;
}
/* 2. variable in hashtable "extra_vars" */
/* 2. variable in hashtable "user_vars" or "extra_vars" */
ptr_value = hashtable_get (eval_context->user_vars, text);
if (ptr_value)
{
value = strdup (ptr_value);
goto end;
}
if (eval_context->extra_vars)
{
ptr_value = hashtable_get (eval_context->extra_vars, text);
@@ -1668,6 +1696,14 @@ eval_replace_vars_cb (void *data, const char *text)
goto end;
}
/* 25. define a variable */
if (strncmp (text, "define:", 7) == 0)
{
eval_string_define (text + 7, eval_context);
value = strdup ("");
goto end;
}
/* 25. option: if found, return this value */
if (strncmp (text, "sec.data.", 9) == 0)
{
@@ -2333,6 +2369,7 @@ eval_expression (const char *expr, struct t_hashtable *pointers,
struct t_hashtable *extra_vars, struct t_hashtable *options)
{
struct t_eval_context context, *eval_context;
struct t_hashtable *user_vars;
int condition, rc, pointers_allocated, regex_allocated, debug_id;
int ptr_window_added, ptr_buffer_added;
long number;
@@ -2347,6 +2384,7 @@ eval_expression (const char *expr, struct t_hashtable *pointers,
return NULL;
condition = 0;
user_vars = NULL;
pointers_allocated = 0;
regex_allocated = 0;
regex = NULL;
@@ -2371,10 +2409,17 @@ eval_expression (const char *expr, struct t_hashtable *pointers,
pointers_allocated = 1;
}
user_vars = hashtable_new (32,
WEECHAT_HASHTABLE_STRING,
WEECHAT_HASHTABLE_STRING,
NULL,
NULL);
eval_context = &context;
eval_context->pointers = pointers;
eval_context->extra_vars = extra_vars;
eval_context->user_vars = user_vars;
eval_context->extra_vars_eval = 0;
eval_context->prefix = default_prefix;
eval_context->suffix = default_suffix;
@@ -2506,6 +2551,8 @@ eval_expression (const char *expr, struct t_hashtable *pointers,
if (ptr_buffer_added)
hashtable_remove (pointers, "buffer");
}
if (user_vars)
hashtable_free (user_vars);
if (regex && regex_allocated)
{
regfree (regex);
+1
View File
@@ -73,6 +73,7 @@ struct t_eval_context
{
struct t_hashtable *pointers; /* pointers used in eval */
struct t_hashtable *extra_vars; /* extra variables used in eval */
struct t_hashtable *user_vars; /* user-defined variables */
int extra_vars_eval; /* 1 if extra vars must be evaluated */
const char *prefix; /* prefix (default is "${") */
const char *suffix; /* suffix (default is "}") */
+8
View File
@@ -853,6 +853,14 @@ TEST(CoreEval, EvalExpression)
WEE_CHECK_EVAL("", "${translate:}");
WEE_CHECK_EVAL("abcdef", "${translate:abcdef}");
/* test user variables */
WEE_CHECK_EVAL("", "${define:}");
WEE_CHECK_EVAL("", "${define:test}");
WEE_CHECK_EVAL("", "${define:test,value}");
WEE_CHECK_EVAL("value", "${define:test,value}${test}");
WEE_CHECK_EVAL("8", "${define:test,${calc:5+3}}${test}");
WEE_CHECK_EVAL("value", "${define:buffer,value}${buffer}");
/* test option */
hashtable_set (secure_hashtable_data, "sec_option", "sec_value");
WEE_CHECK_EVAL("sec_value", "${sec.data.sec_option}");