Skip to content

Instantly share code, notes, and snippets.

@bcambel
Forked from mishok13/gist:8707503
Created January 30, 2014 12:43
Show Gist options
  • Select an option

  • Save bcambel/8707603 to your computer and use it in GitHub Desktop.

Select an option

Save bcambel/8707603 to your computer and use it in GitHub Desktop.
$template TestFormat,"Message: %msg%\n"
$template TestFile,"/tmp/test_%$year%%$month%%$day%%$hour%.log"
# Writes matching messages to path defined by TestFile template in TestFormat format
:syslogtag, contains, "test" -?TestFile;TestFormat
# Drops messages matching this syslog tag
:syslogtag, contains, "test" ~
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment