Skip to content

Commit

Permalink
Merge pull request #137 from ltratt/doc_updates
Browse files Browse the repository at this point in the history
Update documentation with new `%x %?` feature.
  • Loading branch information
vext01 authored Apr 4, 2024
2 parents 0f7998c + 6645988 commit 4f94c26
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ listen = "<ip-address>:<port>";
github {
match ".*" {
cmd = "/path/to/prps/%o/%r %e %j";
errorcmd = "cat %s | mailx -s \"snare error: github.com/%o/%r\" [email protected]";
errorcmd = "cat %s | mailx -s \"snare error: github.com/%o/%r: %x %?\" [email protected]";
secret = "<secret>";
}
}
Expand All @@ -70,8 +70,9 @@ where:
they have completed.
* `errorcmd` is the command that will be run when a `cmd` exits
unsuccessfully. In this example, an email is sent to `[email protected]`
with a body consisting of the comined stedrr/stdout. This assumes that you
have installed, set-up, and enabled a suitable `sendmail` clone.
with a title indicating the reason for non-zero exit (`%x %?`) and a body
consisting of the comined stedrr/stdout. This assumes that you have
installed, set-up, and enabled a suitable `sendmail` clone.
* `secret` is the GitHub secret used to sign the webhook request and thus
allowing `snare` to tell the difference between genuine webhook requests
and those from malfeasants.
Expand Down Expand Up @@ -113,7 +114,7 @@ repository:
```sh
#! /bin/sh

set -euf
set -eufx

# A list of email addresses separated by spaces.
EMAILS="[email protected] [email protected]"
Expand Down

0 comments on commit 4f94c26

Please sign in to comment.