1
0
mirror of https://github.com/pypiserver/pypiserver synced 2024-11-09 16:45:51 +01:00

fix choose_server to return "auto" instead of None.

passing server=None to bottle won't work, we need to pass auto here.
This commit is contained in:
Ralf Schmitt 2011-07-29 13:24:47 +02:00
parent d956f7ce67
commit 475bd9e1c6

@ -89,14 +89,13 @@ def server_static(filename):
def choose_server(): def choose_server():
server = "auto"
for x in ["paste", "cherrypy", "twisted"]: for x in ["paste", "cherrypy", "twisted"]:
try: try:
__import__(x) __import__(x)
return x return x
except: except:
pass pass
return "auto"
def usage(): def usage():
print """pypiserver [-p PORT] [-r PACKAGES_DIR] print """pypiserver [-p PORT] [-r PACKAGES_DIR]