[Zope-Checkins] CVS: Zope/lib/python/Zope - __init__.py:1.35.36.5

Stefan H. Holek stefan at epy.co.at
Fri May 28 11:26:15 EDT 2004


Update of /cvs-repository/Zope/lib/python/Zope
In directory cvs.zope.org:/tmp/cvs-serv23182

Modified Files:
      Tag: Zope-2_7-branch
	__init__.py 
Log Message:
Commit my stab at #1233. 


=== Zope/lib/python/Zope/__init__.py 1.35.36.4 => 1.35.36.5 ===
--- Zope/lib/python/Zope/__init__.py:1.35.36.4	Tue May 18 11:34:26 2004
+++ Zope/lib/python/Zope/__init__.py	Fri May 28 11:25:44 2004
@@ -44,13 +44,17 @@
         # Already began (and maybe finished) startup, so don't run again
         return
     _began_startup = 1
+    # Load configuration file from (optional) environment variable
+    # Also see http://zope.org/Collectors/Zope/1233
+    import os
+    configfile = os.environ.get('ZOPE_CONFIG')
+    if configfile is not None:
+        configure(configfile)
     from Zope.App.startup import startup as _startup
     _startup()
 
 def app(*args, **kw):
     """Utility for scripts to open a connection to the database"""
-    if bobo_application == None:
-        configure()
     startup()
     return bobo_application(*args, **kw)
 




More information about the Zope-Checkins mailing list