Plugins
=======

It's pretty easy to write puddletag plugins provided you know a bit of Python. If anything's unclear don't hesitate mailing me (concentricpuddle@gmail.com) to complain. Follow the same protocol if you find any errors.

Required Info
-------------

puddletag plugins are stored in **~/.puddletag/plugins**. In order for a plugin to be registered the following tree structure is required.::

    ~/.puddletag/plugins
        --\modulename
        ----\__init__.py
        ----\info
        

Plugins will be imported using **modulename**, as such only valid in Python module names (no spaces, periods, unicode, etc.) are allowed.

**info** is a INI file containing the plugin information. Use the following structure and keep in mind that all keys are case sensitive.

.. code-block:: ini

    [info]
    name = Plugin Name
    author = Author Name
    version = 1.0
    puddletag_version = 0.9.3
    description = Description of what the plugin has/does.

+ **name**: The name of the plugin as it'll be displayed to a puddletag user.
+ **author**: Add the names of people responsible for this mofo.
+ **version**: The version number of your plugin.
+ **puddletag_version**: The version of puddletag this plugin was created with. May be used for backward compatibility if the plugin interface changes.
+ **description**: Add a short synopsis of what your plugin does.

Your plugin will not be loaded unless all this information is present.

Plugin Examples:
----------------

The :download:`Function plugin example <functionplugin.tar.gz>` contains a short tutorial on writing scripting functions and Functions that can be part of an action.

The :download:`Tag Source Example <tagsource.tar.gz>` contains puddletag's Amazon tag source with a lot of comments.