You are not logged in Log in Join
You are here: Home » Members » slinkp » CMFBoringTool, a minimalistic demo CMF Tool » CMFBoringTool » View Document

Log in
Name

Password

 

CMFBoringTool

readme for CMFBoringTool.

CMFBoring

Author

Paul M. Winkler http://www.slinkp.com

Description

A demo of a very simple CMF tool, showing how to get up and running with a new tool.

Like the famous Boring and Minimal zope products, it doesn't do anything interesting (hence the name).

The code contains many comments that should help you figure out what is going on. Use the source, luke! It's the whole point of this silly product.

Installation

... in case you want to add this boring tool to a real Plone or CMFDefault site :-)

Put the CMFBoringTool directory in your zope Products directory. Restart zope.

If you are using plone's QuickInstallerTool, use it to install the tool.

Otherwise, create an External Method in your CMF site, with these properties::

Title: (doesn't matter) Module Name: CMFBoringTool.Install Function: install

Click "Save Changes", then click the "Test" tab.

How To Create Your Own Tool Based on CMFBoringTool

Copy the entire CMFBoring directory to a new one, name of your choice.

Rename ALL files with the name "boring" to something meaningful.

Edit ALL files to change the word "boring" to something meaningful. Be careful that all your changes to filenames are reflected in the code (e.g. module names, skin paths, etc. must reflect reality).

You might want to try restarting Zope and installing your new product at this time, just to be sure you didn't make a mistake in the renaming.

Then it's time to make your tool less boring. This is left as an exercise for the reader ;-)

Package Contents

This is a typical of a simple CMF Tool, so it may be instructive:

  • README.txt

    This file.

  • version.txt

    Contains a numeric release version. Optional but highly recommended - don't make people guess.

  • LICENSE.txt

    Copyright and license terms. Optional but highly recommended - don't make people guess.

  • __init__.py

    Initializes the module and makes it into a proper python package. All zope Products need this.

  • tool.gif

    An icon used for this tool in the Zope Management Interface. If you look real close, this one says "Boring". You probably will not want to use that for real tools :-)

  • BoringTool.py

    Contains the class definition of the tool.

  • Extensions/Install.py

    External Method code for installing the tool in a CMF site.

  • Extensions/__init__.py

    Makes Extensions into a package. Needed so your external method can find its code.

  • skins/boring_tool_skins

    Contains templates, scripts, images, etc. used by this tool.

  • skins/boring_tool_skins/boring_main_form.pt

    A simple demo of a filesystem Page Template.