Update readme with filters not and header

This commit is contained in:
finga 2021-11-17 15:19:38 +01:00
parent 8c9d9e63f2
commit 181edf589c

View file

@ -98,16 +98,17 @@ hooks:
- secret_key_02
filter:
or:
- json:
- not:
json:
pointer: /ref
regex: refs/heads/master
regex: refs/heads/dev
- and:
- json:
pointer: /ref
regex: refs/heads/a_branch
- json:
pointer: /after
regex: f6e5fe4fe37df76629112d55cc210718b6a55e7e
- header:
field: X-Gitea-Event
regex: push
```
##### Command
@ -163,10 +164,20 @@ hook should be executed.
###### Conjunction Filters
Conjunction filters contain lists of other filters.
- `not`: Logical negation.
- `and`: Logical conjunction.
- `or`: Logical disjunction.
###### Concrete Filters
- `header`:
The `header` filter matches a regular expression on a field from the
received http(s) request header.
- `field`: The header field which should be matched.
- `regeq`: Regular expression which has to match the specified
header field.
- `json`:
The `json` filter matches a regular expression on a field from the