changeset 5:043088856f0d tip

clean up this bridge a bit
author Jeff Hammel <jhammel@mozilla.com>
date Thu, 16 Jun 2011 08:47:33 -0700
parents 041ba864496f
children
files hgpaste/__init__.py hgpaste/factory.py setup.py
diffstat 3 files changed, 12 insertions(+), 6 deletions(-) [+]
line wrap: on
line diff
--- a/hgpaste/__init__.py
+++ b/hgpaste/__init__.py
@@ -1,1 +1,1 @@
-#
+from factory import *
--- a/hgpaste/factory.py
+++ b/hgpaste/factory.py
@@ -1,5 +1,12 @@
-def make_app(global_conf, config_file):
+__all__ = ['wsgi_app', 'make_app']
+
+def wsgi_app(config_file):
+    """wsgi application"""
     from mercurial import demandimport; demandimport.enable()
     from mercurial.hgweb.hgwebdir_mod import hgwebdir
     application = hgwebdir(config_file)
-    return application
+    return application    
+
+def make_app(global_conf, config_file):
+    """make an app for paster"""
+    return wsgi_app(config_file)
--- a/setup.py
+++ b/setup.py
@@ -1,16 +1,15 @@
 from setuptools import setup, find_packages
-import sys, os
 
-version = '0.1'
+version = '0.1.1'
 
 setup(name='hgpaste',
       version=version,
-      description="front-end to serve a hg webdir with paste",
+      description="front-end to serve a hg webdir with paste and other",
       long_description="""\
 """,
       classifiers=[], # Get strings from http://pypi.python.org/pypi?%3Aaction=list_classifiers
       keywords='paste hg',
       author='Jeff Hammel',
       author_email='k0scist@gmail.com',
       url='http://k0s.org',
       license='GPL',