Add --debug=presub to the help text.
authorstevenknight <stevenknight@fdb21ef1-2011-0410-befe-b5e4ea1792b1>
Wed, 24 Mar 2004 14:08:12 +0000 (14:08 +0000)
committerstevenknight <stevenknight@fdb21ef1-2011-0410-befe-b5e4ea1792b1>
Wed, 24 Mar 2004 14:08:12 +0000 (14:08 +0000)
git-svn-id: http://scons.tigris.org/svn/scons/trunk@929 fdb21ef1-2011-0410-befe-b5e4ea1792b1

src/CHANGES.txt
src/engine/SCons/Script/__init__.py

index 8eef6a76e6f5f810ef00d8f3d6266514ec11551f..c421d120152a2494eb25a95c475c883e627b5769 100644 (file)
@@ -27,6 +27,10 @@ RELEASE 0.96 - XXX
   - Fix use of $MSVS_IGNORE_IDE_PATHS, which was broken when we added
     support for $MSVS_USE_MFC_DIRS last release.
 
+  From Gary Oberbrunner:
+
+  - Add a --debug=presub option to print actions prior to substitution.
+
 
 
 RELEASE 0.95 - Mon, 08 Mar 2004 06:43:20 -0600
index c59ce69a7911d3e3fdabf21e4e846c17240cd723..52d0db2189b19b4c9643f59c2c79bf6260a31eee 100644 (file)
@@ -493,9 +493,11 @@ class OptParser(OptionParser):
                         help="Search up directory tree for SConstruct,       "
                              "build all Default() targets.")
 
-        def opt_debug(option, opt, value, parser):
-            if value in ["count", "dtree", "includes", "memory", "objects",
-                         "pdb", "presub", "time", "tree"]:
+        debug_options = ["count", "dtree", "includes", "memory", "objects",
+                         "pdb", "presub", "time", "tree"]
+
+        def opt_debug(option, opt, value, parser, debug_options=debug_options):
+            if value in debug_options:
                 setattr(parser.values, 'debug', value)
             else:
                 raise OptionValueError("Warning:  %s is not a valid debug type" % value)
@@ -503,7 +505,7 @@ class OptParser(OptionParser):
                         callback=opt_debug, nargs=1, dest="debug",
                         metavar="TYPE",
                         help="Print various types of debugging information: "
-                             "count, dtree, includes, memory, objects, pdb, time, tree.")
+                             "%s." % string.join(debug_options, ", "))
 
         self.add_option('-f', '--file', '--makefile', '--sconstruct',
                         action="append", nargs=1,