<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -35,7 +35,7 @@ import sys
 
 
 
-VERSION = '0.26'
+VERSION='0.26'
 pattern = '.flashbake'
 
 def main():
@@ -225,13 +225,13 @@ def __context_only(options, project_dir, control_file, control_config, hot_files
         logging.error('Error: %s' % str(error))
         return 1
     except PluginError, error:
-        handlebadplugin(error)
+        __handle_bad_plugin(error)
         return 1
 
 
 def __handle_bad_plugin(plugin_error):
     logging.debug('Plugin error, %s.' % plugin_error)
-    if plugin_error.reason == PLUGIN_ERRORS.unknown_plugin:
+    if plugin_error.reason == PLUGIN_ERRORS.unknown_plugin or plugin_error.reason == PLUGIN_ERRORS.invalid_plugin:
         logging.error('Cannot load plugin, %s.' % plugin_error.plugin_spec)
         return
 </diff>
      <filename>flashbake/console.py</filename>
    </modified>
    <modified>
      <diff>@@ -21,11 +21,13 @@
 '''  music.py - Plugin for gathering last played tracks from music player. '''
 
 from flashbake.plugins import AbstractMessagePlugin, AbstractMessagePlugin
+import flashbake
 import logging
 import os
 import os.path
 import sqlite3
 import string
+import subprocess
 import time
 
 
@@ -75,33 +77,33 @@ limit %d&quot;&quot;&quot;
 
 class iTunes(AbstractMessagePlugin):
     ''' Based on Andrew Wheiss' plugin which is MIT licensed which should be compatible. '''
-    def __init__(self):
+    def __init__(self, plugin_spec):
+        AbstractMessagePlugin.__init__(self, plugin_spec)
         self.define_property('osascript')
-        
-    def init(self, config):
-        if self.osascript is None:
-            self.osascript = flashbake.findexecutable('osascript')
-            
+
     def addcontext(self, message_file, config):
         &quot;&quot;&quot; Get the track info and write it to the commit message &quot;&quot;&quot;
+        if self.osascript is None:
+            self.osascript = flashbake.find_executable('osascript')
+
         info = self.trackinfo()
 
         if info is None:
             message_file.write('Couldn\'t get current track.\n')
         else:
-            message_file.write('%s' % info)
+            message_file.write('Currently playing in iTunes:\n%s' % info)
 
         return True
 
-    def trackinfo():
+    def trackinfo(self):
         ''' Call the AppleScript file. '''
         if self.osascript is None:
             return None
         directory = os.path.dirname(__file__)
         script_path = os.path.join(directory, 'current_track.scpt')
-        
+
         args = [self.osascript, script_path]
         proc = subprocess.Popen(args, stdout=subprocess.PIPE, stderr=subprocess.STDOUT,
-                             close_fds = True)
-        
+                             close_fds=True)
+
         return proc.communicate()[0]</diff>
      <filename>flashbake/plugins/music.py</filename>
    </modified>
    <modified>
      <diff>@@ -2,10 +2,11 @@
 #
 # setup.py for flashbake
 from setuptools import setup, find_packages
-import flashbake.console
+
+
 
 setup(name='flashbake',
-        version=flashbake.console.VERSION,
+        version='0.26',
         author=&quot;Thomas Gideon&quot;,
         author_email=&quot;cmdln@thecommandline.net&quot;,
         url=&quot;http://thecommandline.net&quot;,</diff>
      <filename>setup.py</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>d9b3cbdea5322de596f435dcb30fba8c0156a5fd</id>
    </parent>
  </parents>
  <author>
    <name>Thomas Gideon</name>
    <email>cmdln@thecommandline.net</email>
  </author>
  <url>http://github.com/commandline/flashbake/commit/7980762f6b65105debf72bc208924847ab03f169</url>
  <id>7980762f6b65105debf72bc208924847ab03f169</id>
  <committed-date>2009-11-06T12:44:49-08:00</committed-date>
  <authored-date>2009-11-06T12:44:49-08:00</authored-date>
  <message>Fixed iTunes plugin.</message>
  <tree>e0133285bd34f3f28e1f9026751fb43867025a63</tree>
  <committer>
    <name>Thomas Gideon</name>
    <email>cmdln@thecommandline.net</email>
  </committer>
</commit>
