Purge routes package from MG (#507)
authorSebastian Spaeth <Sebastian@SSpaeth.de>
Tue, 20 Nov 2012 08:25:41 +0000 (09:25 +0100)
committerSebastian Spaeth <Sebastian@SSpaeth.de>
Tue, 20 Nov 2012 08:29:37 +0000 (09:29 +0100)
We were not actually using the routes package anymore, but it was
still mentioned in the documention. Adapt the plugin documentation to
actually represent reality, although I don't like the API design.
(but this is for another day)

Signed-off-by: Sebastian Spaeth <Sebastian@SSpaeth.de>
docs/source/siteadmin/codebase.rst
mediagoblin/tools/pluginapi.py

index 3ef91290bad39aaacb11087ff91a1e898073b137..22f4e18bf3d63254157a5f878f042928d23b0686 100644 (file)
@@ -68,8 +68,6 @@ Software Stack
   * `WebOb <http://pythonpaste.org/webob/>`_: nice abstraction layer
     from HTTP requests, responses and WSGI bits
 
-  * `Routes <http://routes.groovie.org/>`_: for URL routing
-
   * `Beaker <http://beaker.groovie.org/>`_: for handling sessions and
     caching
 
index 1752dfc845cbbe22c9c007c6dadc430dfbc32395..38ab631baf54b36d89cf5d722cf0677cefa32ba9 100644 (file)
@@ -145,16 +145,14 @@ def register_routes(routes):
 
     Example passing in a single route:
 
-    >>> from routes import Route
-    >>> register_routes(Route('about-view', '/about',
-    ...     controller=about_view_handler))
+    >>> register_routes(('about-view', '/about',
+    ...     'mediagoblin.views:about_view_handler'))
 
     Example passing in a list of routes:
 
-    >>> from routes import Route
     >>> register_routes([
-    ...     Route('contact-view', '/contact', controller=contact_handler),
-    ...     Route('about-view', '/about', controller=about_handler)
+    ...     ('contact-view', '/contact', 'mediagoblin.views:contact_handler'),
+    ...     ('about-view', '/about', 'mediagoblin.views:about_handler')
     ... ])