[Checkins] SVN: Sandbox/darrylcousins/mars.adapter/s Egg ready
Darryl Cousins
darryl at darrylcousins.net.nz
Fri Jul 13 06:50:45 EDT 2007
Log message for revision 77838:
Egg ready
Changed:
U Sandbox/darrylcousins/mars.adapter/setup.py
D Sandbox/darrylcousins/mars.adapter/src/adapter/
U Sandbox/darrylcousins/mars.adapter/src/mars/adapter/README.txt
U Sandbox/darrylcousins/mars.adapter/src/mars/adapter/tests/ftesting.zcml
-=-
Modified: Sandbox/darrylcousins/mars.adapter/setup.py
===================================================================
--- Sandbox/darrylcousins/mars.adapter/setup.py 2007-07-13 10:49:37 UTC (rev 77837)
+++ Sandbox/darrylcousins/mars.adapter/setup.py 2007-07-13 10:50:44 UTC (rev 77838)
@@ -11,11 +11,8 @@
author_email='darryl.cousins at tfws.org.nz',
url='http://www.tfws.org.nz/mars',
description="""\
-Martian is a library that allows the embedding of configuration
-information in Python code. Martian can then grok the system and
-do the appropriate configuration registrations.
-
-This package uses martian to register simple adapters.""",
+This package uses ``martian`` and ``grok`` to register simple adapters
+for applications built on the ``zope`` framework.""",
long_description=(
read('src/mars/adapter/README.txt')
),
@@ -26,71 +23,22 @@
license='ZPL',
dependency_links = ['http://download.zope.org/distribution'],
extras_require = dict(
- test = ['zope.app.appsetup',
- 'zope.app.authentication',
- 'zope.app.component',
- 'zope.app.container',
- 'zope.app.error',
- 'zope.app.form',
- 'zope.app.publisher',
- 'zope.app.publication',
- 'zope.app.security',
- 'zope.app.securitypolicy',
- 'zope.app.twisted',
- 'zope.app.wsgi',
- 'zope.contentprovider',
- 'zope.app.intid',
- 'z3c.formdemo',
- 'z3c.etestbrowser',
- 'zope.app.zcmlfiles',
- 'zope.app.testing',
- 'mars.template'],
- ),
+ test=['zope.app.testing',
+ 'zope.testbrowser',
+ 'zope.app.zcmlfiles',
+ 'zope.app.securitypolicy',
+ 'zope.app.authentication',
+ 'z3c.layer',
+ ]
+ ),
install_requires = [
'setuptools',
- 'simplejson',
- 'grok',
- 'martian',
- 'lxml',
- 'pytz',
- 'ZODB3',
- 'z3c.csvvocabulary',
- 'z3c.form',
- 'z3c.formui',
- 'z3c.layer',
- 'z3c.pagelet',
- 'z3c.template',
- 'z3c.viewlet',
- 'z3c.zrtresource',
- 'z3c.formdemo',
- 'zc.resourcelibrary',
- 'zc.table',
- 'zope.annotation',
- 'zope.contentprovider',
- 'zope.app.catalog',
- 'zope.app.folder',
- 'zope.app.container',
- 'zope.app.pagetemplate',
- 'zope.app.session',
+ 'zope.app.intid',
+ 'zope.app.catalog',
'zope.component',
'zope.interface',
- 'zope.location',
- 'zope.pagetemplate',
'zope.publisher',
- 'zope.rdb',
- 'zope.schema',
- 'zope.traversing',
- 'zope.viewlet',
+ 'grok',
+ 'martian',
],
)
- # 'zope.app.pagetemplate',
- # 'zope.app.testing',
- # 'zope.configuration',
- # 'zope.dottedname',
- # 'zope.event',
- # 'zope.formlib',
- # 'zope.lifecycleevent',
- # 'zope.security',
- # 'zope.testing',
-
-
Modified: Sandbox/darrylcousins/mars.adapter/src/mars/adapter/README.txt
===================================================================
--- Sandbox/darrylcousins/mars.adapter/src/mars/adapter/README.txt 2007-07-13 10:49:37 UTC (rev 77837)
+++ Sandbox/darrylcousins/mars.adapter/src/mars/adapter/README.txt 2007-07-13 10:50:44 UTC (rev 77838)
@@ -2,27 +2,52 @@
Mars Adapter
============
-Martian is a library that allows the embedding of configuration
-information in Python code. Martian can then grok the system and
-do the appropriate configuration registrations.
+Introduction
+------------
-z3c packages bring significant clarity and a pattern for forms, view and
-templates.
+`Grok`_ is a project which seeks to provide convention over configuration.
-This package uses martian to register adapter factories.
+``Martian`` grew from `Grok`_:
+Martian is a library that allows the embedding of configuration information in
+Python code. Martian can then grok the system and do the appropriate
+configuration registrations.
+
+.. _Grok: http://grok.zope.org/
+
+Mars Adapter
+------------
+
+The mars.adapter package provides the means of creating and configuring simple
+``adapters`` for an application using Zope3.
+
Example Code
------------
::
- Code
+ class DefaultDate(mars.adapter.AdapterFactory):
+ grok.name('default')
+ mars.adapter.factory(z3c.form.widget.ComputedWidgetAttribute(
+ lambda adapter: datetime.date.today(),
+ field=IHelloWorld['when'], view=IAddForm))
-Directives
-----------
-Please see ``directive.txt``.
+Directives specific to this package
+-----------------------------------
+* mars.adapter.factory(factory):
+ The factory to be registered
+ **Required**
+
+Relevant grok directives
+------------------------
+
+* grok.name(name):
+ If defined the factory will be registered as a `named adapter`.
+ Default: empty string
+
+
Tests
-----
Modified: Sandbox/darrylcousins/mars.adapter/src/mars/adapter/tests/ftesting.zcml
===================================================================
--- Sandbox/darrylcousins/mars.adapter/src/mars/adapter/tests/ftesting.zcml 2007-07-13 10:49:37 UTC (rev 77837)
+++ Sandbox/darrylcousins/mars.adapter/src/mars/adapter/tests/ftesting.zcml 2007-07-13 10:50:44 UTC (rev 77838)
@@ -2,7 +2,7 @@
xmlns:meta="http://namespaces.zope.org/meta"
xmlns:browser="http://namespaces.zope.org/browser"
i18n_domain="zope"
- package="mars.template.tests">
+ package="mars.adapter.tests">
<include package="grok" file="meta.zcml" />
<include package="mars.adapter" file="meta.zcml" />
More information about the Checkins
mailing list