1

How can I clear growl notifications from the command line?

I have a server running all my unit tests and when an error/failure arrives I get a growl notification with the number of errors (also a little arduino light next to my desk changes color), so when I fix the error I want to automatically clear the growl errors. Is there a way to send growl a message or run something in the command line to clear them?

I could be evil and just kill growl and restart it. I have the latest version bought in the appstore and I am using osx/lion if that helps

Thanks

4

1 回答 1

2

我相信这不能从 GAB/GNTP 层完成,但绝对可以通过 AppleEvents 完成。

有关 Growl Control Suite 的详细信息,请参阅http://growl.info/documentation/applescript-support.php#growlcontrol。示例脚本展示了如何执行所有您可以执行的操作,包括关闭所有打开的通知。

如果您不知道如何从命令行运行 AppleScript,请参阅 osascript 命令。

于 2012-06-16T00:00:53.717 回答