File tree 1 file changed +19
-2
lines changed
1 file changed +19
-2
lines changed Original file line number Diff line number Diff line change @@ -237,7 +237,7 @@ rules:
237
237
238
238
See [` text/template`](https://pkg.go.dev/text/template) on how to template.
239
239
240
- Each `*_template` config variable has access to the [Envelope](./internal/models/envelope.go) model via the `.` operator.
240
+ Each `*_template` has access to the [Envelope](./internal/models/envelope.go) model via the `.` operator.
241
241
242
242
The following custom functions are available in endpoint templates.
243
243
@@ -247,9 +247,25 @@ The following custom functions are available in endpoint templates.
247
247
248
248
# # Expressions
249
249
250
- Rule expressions are just [templates](#templates) without `{{ }}` and custom functions.
250
+ Rule expressions are just [`text/template`](https://pkg.go.dev/text/template) without `{{ }}`.
251
+ The [Envelope](./internal/models/envelope.go) model can be accessed via the `.` operator.
251
252
They should always evaluate to a boolean expression.
252
253
254
+ Example :
255
+
256
+ ` ` `
257
+ or
258
+ (eq .Message.Subject "cam-1")
259
+ (.Message.To.EQ "my-name@example.com")
260
+ (eq .Message.From "unleashed@example.com")
261
+ ` ` `
262
+
263
+ This expression will pass if one of the following is true.
264
+
265
+ - The message's subject equals "cam-1"
266
+ - The message is to "<my-name@example.com>"
267
+ - The message is from "<unleashed@example.com>"
268
+
253
269
# Docker
254
270
255
271
# # Docker Compose
@@ -330,6 +346,7 @@ make dev-web
330
346
331
347
# To Do
332
348
349
+ - refactor: WAY TOO MANY TOOLS TO BUILD THE PROGRAM, REMOVE SOME
333
350
- feat: read [ mbox] ( https://access.redhat.com/articles/6167512 ) files
334
351
- feat: IMAP for viewing mail
335
352
- feat: OpenAPI
You can’t perform that action at this time.
0 commit comments