We're going to be moving away from the --d_plugins && msg() calls.
The reader's digest version is:
use Slim::Utils::Log;
my $log = Slim::Utils::Log->addLogCategory({
'category' => 'plugin.itunes',
'defaultLevel' => 'WARN',
});
Replacing itunes with your plugin's name.
You can then use Log::Log4perl calls on your $log object.
For quick warnings, etc do:
logWarning("Foo!");
or
logError("Bar");
There's also a logBacktrace("Arrr!");
Note that no newline is needed.
I'm starting a wiki page at:
http://wiki.slimdevices.com/index.cgi?Debugging
Which will contain this information and more.
--
Dan Sully
------------------------------------------------------------------------
Dan Sully's Profile: http://forums.slimdevices.com/member.php?userid=1
View this thread: http://forums.slimdevices.com/showthread.php?t=28923
_______________________________________________
plugins mailing list
[email protected]
http://lists.slimdevices.com/lists/listinfo/plugins