ASL: Test apps
In the course of writing these posts, I wrote about half a dozen test apps that I used to experiment with ASL’s behavior. A few of them are generally-useful enough that I’m going to share them with you now:
Next in the ASL series: Executive summary and wrap-up
July 8th, 2008 at 18:39:42
I’ve only played with aslsearch, but I noticed that it doesn’t seem to ever emit it’s usage info.
I had a custom ASL extension I hacked up for Tiger that funneled incoming network syslog messages to unique logs per host. (Boy was that fun!) I’ve been trying to replace that with a simple query in Console.app.
While experimenting with aslsearch to build that query, I noticed that a not equal combined with a regex will never match: I was trying to do !={~}(foo.com|localhost).
July 8th, 2008 at 22:57:59
alexr: See Searching, which describes the behavior of
ASL_QUERY_OP_REGEX
.As such, the correct expression is =~. =={~} will work, but is technically wrong.
Good catch about it never printing its usage. I should make it do that. There is a usage string in the source file, ready to deploy.