changeset 727:036c28e36895

Rename environment variable from EPYDOC to VIFF_NO_WRAP.
author Martin Geisler <mg@daimi.au.dk>
date Thu, 24 Apr 2008 13:13:22 +0200
parents 5fee3ab4741d
children fa33d8c71256
files run.py viff/util.py
diffstat 2 files changed, 9 insertions(+), 9 deletions(-) [+]
line wrap: on
line diff
--- a/run.py	Thu Apr 24 11:56:34 2008 +0200
+++ b/run.py	Thu Apr 24 13:13:22 2008 +0200
@@ -126,7 +126,7 @@
     target = "%s/api" % build
     ensure_dir(target)
     execute(["epydoc", "-vv", "--config", "epydoc.conf"],
-            {'EPYDOC': 'YES', 'target': target})
+            {'VIFF_NO_WRAP': 'YES', 'target': target})
 
 @command('coverage', 'build')
 def coverage(build):
--- a/viff/util.py	Thu Apr 24 11:56:34 2008 +0200
+++ b/viff/util.py	Thu Apr 24 13:13:22 2008 +0200
@@ -64,18 +64,18 @@
     order to ensure that they end up with correct C{__name__} and
     C{__doc__} attributes.
 
-    In addition, if the environment variable C{EPYDOC} is defined,
-    then the wrapper functions will be turned into functions that I{do
-    not} wrap -- instead they let their argument function through
-    unchanged. This is done so that epydoc can see the true function
-    arguments when generating documentation. Just remember that your
-    code will break if C{EPYDOC} is set, so it should only be used
-    when epydoc is being run.
+    In addition, if the environment variable C{VIFF_NO_WRAP} is
+    defined, then the wrapper functions will be turned into functions
+    that I{do not} wrap -- instead they let their argument function
+    through unchanged. This is done so that epydoc and Sphinx can see
+    the true function arguments when generating documentation. Just
+    remember that your code will break if C{VIFF_NO_WRAP} is set, so
+    it should only be used when documentation is being generated.
 
     @param func: the function that will be wrapped.
     @type func: callable
     """
-    if os.environ.get('EPYDOC'):
+    if os.environ.get('VIFF_NO_WRAP'):
         # Return a decorator which ignores the functions it is asked
         # to decorate and instead returns func:
         return lambda _: func