-
New Feature Request
-
Resolution: Unresolved
-
Trivial
-
None
-
None
It would be neat if vfs.file.contents[] had some arguments for mode and lines. For example, default could be vfs.file.contents[<file>,<encoding>,<mode>,<lines>] where mode is 'all' by default. Mode could be something like 'head' or 'tail' and then <lines> could specify the number of lines to gather.
This would be useful when triggering on a size increase or md5sum of a file to include the last line of the file in the action message using item vfs.file.contents[/var/log/my_log_file,utf8,tail,1] to get the last line of the file triggering. Hope someone else may have interest in this also.