Use the README.txt file to set the long description of a Python egg
How to tell setuptools to use the 'README.txt' file of a Python egg to generate its long description.
Instead of having the long description of a Python egg hardcoded in the setup.py file, it is possible (and cleaner) to ask setuptools to open the README.txt file of the package while generating the egg informations (*).
One advantage is that the README file will be used as the main content of the project page on cheeseshop. It makes it easier to keep a well formatted documentation that doesn't require to download the full package (then tarball expand, then open README.txt…) for being accessible/readable.
In the setup.py config file, use the following code (in this case, for a theme for Plone):
from setuptools import setup, find_packages(*) Python egg generation/release process is described in Martins tutorial on zc.buildout
version = '0.1'
setup(name='plonetheme.mytheme',
version=version,
description="An installable theme for Plone 3.0",
long_description = open("README.txt").read(), # Get more strings from http://www.python.org/pypi?%3Aaction=list_classifiers classifiers=[ "Framework :: Plone", "Framework :: CMF", "Framework :: Zope2", "Programming Language :: Python", "Topic :: Software Development :: Libraries :: Python Modules", ], keywords='web zope plone theme', author='Plone Collective', author_email='product-developers@lists.plone.org', url='https://svn.plone.org/svn/collective/plonetheme.mytheme', license='GPL', packages=find_packages(exclude=['ez_setup']), namespace_packages=['plonetheme'], include_package_data=True, zip_safe=False, install_requires=[ 'setuptools', # -*- Extra requirements: -*- ], entry_points=""" # -*- Entry points: -*- """, )
