[wiki] Remove deprecated concat examples

Signed-off-by: Knut Ahlers <knut@ahlers.me>
This commit is contained in:
Knut Ahlers 2023-04-22 21:09:44 +02:00
parent aa420b4afd
commit f562c2fec5
Signed by: luzifer
GPG key ID: D91C3E91E4CAD6F5
2 changed files with 6 additions and 19 deletions

View file

@ -7,8 +7,8 @@
- actions:
- type: respond
attributes:
message: '{{ variable (concat ":" "genericcmd" .channel (group 1)) }}'
disable_on_template: '{{ eq (variable (concat ":" "genericcmd" .channel (group 1))) "" }}'
message: '{{ variable (list "genericcmd" .channel (group 1) | join ":") }}'
disable_on_template: '{{ eq (variable (list "genericcmd" .channel (group 1) | joih ":")) "" }}'
match_channels: ['#mychannel']
match_message: '^!([^\s]+)(?: |$)'
@ -16,7 +16,7 @@
- actions:
- type: setvariable
attributes:
variable: '{{ concat ":" "genericcmd" .channel (group 1) }}'
variable: '{{ list "genericcmd" .channel (group 1) | join ":" }}'
set: '{{ group 2 }}'
- type: respond
attributes:
@ -29,7 +29,7 @@
- actions:
- type: setvariable
attributes:
variable: '{{ concat ":" "genericcmd" .channel (group 1) }}'
variable: '{{ list "genericcmd" .channel (group 1) | join ":" }}'
clear: true
- type: respond
attributes:

View file

@ -69,19 +69,6 @@ Example:
< 5
```
#### `concat`
Join the given string parts with delimiter (⚠ this replaces the sprig `concat` function: sprig `concat` is not available!)
Syntax: `concat <delimiter> <...parts>`
Example:
```
# {{ concat ":" "test" .username }}
< test:luziferus
```
#### `counterValue`
Returns the current value of the counter which identifier was supplied
@ -91,7 +78,7 @@ Syntax: `counterValue <counter name>`
Example:
```
# {{ counterValue (concat ":" .channel "test") }}
# {{ counterValue (list .channel "test" | join ":") }}
< 5
```
@ -319,7 +306,7 @@ Syntax: `seededRandom <string-seed>`
Example:
```
# Your int this hour: {{ printf "%.0f" (multiply (seededRandom (concat ":" "int" .username (now "2006-01-02 15"))) 100) }}%
# Your int this hour: {{ printf "%.0f" (multiply (seededRandom (list "int" .username (now "2006-01-02 15") | join ":")) 100) }}%
< Your int this hour: 17%
```