<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>netCUBED Blog &#187; notification</title>
	<atom:link href="http://blog.netcubed.de/tag/notification/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.netcubed.de</link>
	<description>Just another web developer's weblog</description>
	<lastBuildDate>Mon, 29 Jun 2009 20:58:35 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Dispatch Catalyst log output to Growl</title>
		<link>http://blog.netcubed.de/2009/05/dispatch-catalyst-log-output-to-growl/</link>
		<comments>http://blog.netcubed.de/2009/05/dispatch-catalyst-log-output-to-growl/#comments</comments>
		<pubDate>Sun, 10 May 2009 17:02:15 +0000</pubDate>
		<dc:creator>Moritz Onken</dc:creator>
				<category><![CDATA[Perl]]></category>
		<category><![CDATA[catalyst]]></category>
		<category><![CDATA[growl]]></category>
		<category><![CDATA[notification]]></category>

		<guid isPermaLink="false">http://blog.netcubed.de/?p=74</guid>
		<description><![CDATA[Growl is a nice notification utility for Mac OS X. There are many applications or plugins avaiable which interact with Growl (e. g. Skype, Mail, VLC etc.).
I thought it would be nice if I could redirect the catalyst debug output to it as well. Log::Dispatch has a nice appender Log::Dispatch::MacGrowl. Load Log::Dispatch as plugin in [...]]]></description>
			<content:encoded><![CDATA[<p><img class="alignright size-medium wp-image-76" title="My App Growls" src="http://blog.netcubed.de/wp-content/uploads/2009/05/bild-5-300x126.png" alt="My App Growls" width="300" height="126" /><a href="http://growl.info/" target="_blank">Growl</a> is a nice notification utility for Mac OS X. There are many applications or plugins avaiable which interact with Growl (e. g. Skype, Mail, VLC etc.).</p>
<p>I thought it would be nice if I could redirect the catalyst debug output to it as well. Log::Dispatch has a nice appender <a href="http://search.cpan.org/perldoc?Log::Dispatch::MacGrowl" target="_blank">Log::Dispatch::MacGrowl</a>. Load Log::Dispatch as plugin in MyApp.pm (after ConfigLoader):</p>

<div class="wp_syntax"><div class="code"><pre class="perl" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">use</span> Catalyst <span style="color: #000066;">qw</span><span style="color: #339933;">/-</span>Debug
                ConfigLoader
                Log<span style="color: #339933;">::</span><span style="color: #006600;">Dispatch</span>
                Static<span style="color: #339933;">::</span><span style="color: #006600;">Simple</span><span style="color: #339933;">/;</span></pre></div></div>

<p>and configure your app accordingly:</p>

<div class="wp_syntax"><div class="code"><pre class="xml" style="font-family:monospace;"><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;Log::Dispatch<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
	class     = MacGrowl
	name      = growl
	app_name  = MyAppGrowls
	title     = MyApp
	sticky    = 0
	min_level = notice
	format    = [%p] %m %n
<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/Log::Dispatch<span style="color: #000000; font-weight: bold;">&gt;</span></span></span></pre></div></div>

<p>I cannot recommend to set <code>min_level</code> to <code>info</code> or below because this will add all start up log statements to be rendered on your screen. Kind of annoying.</p>
<p>Put a log statement anywhere in your code and start up your dev server. A growl notification should appear when you hit the log statement.</p>
<p>You can get a sample application <code>MyAppGrowls</code> from <a href="http://github.com/monken/MyAppGrowls/tree/master" target="_blank">GitHub</a>.</p>
<p>Make sure you have the following modules installed (or run <code>perl Makefile.PL</code>):</p>
<ul>
<li>Catalyst::Plugin::Log::Dispatch</li>
<li>Log::Dispatch::Config</li>
<li>Log::Dispatch::MacGrowl</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://blog.netcubed.de/2009/05/dispatch-catalyst-log-output-to-growl/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>
