$include_dir="/home/hyper-archives/boost-commit/include"; include("$include_dir/msg-header.inc") ?>
Subject: [Boost-commit] svn:boost r78637 - in trunk/tools/inspect: . build/msvc
From: bdawes_at_[hidden]
Date: 2012-05-26 13:51:25
Author: bemandawes
Date: 2012-05-26 13:51:24 EDT (Sat, 26 May 2012)
New Revision: 78637
URL: http://svn.boost.org/trac/boost/changeset/78637
Log:
inspect: Do not inspect files containing "boost-no-inspect". Add boost-no-inspect msgs to output.
Text files modified: 
   trunk/tools/inspect/build/msvc/readme.txt |     6 +++++-                                  
   trunk/tools/inspect/inspect.cpp           |    23 +++++++++++++++--------                 
   2 files changed, 20 insertions(+), 9 deletions(-)
Modified: trunk/tools/inspect/build/msvc/readme.txt
==============================================================================
--- trunk/tools/inspect/build/msvc/readme.txt	(original)
+++ trunk/tools/inspect/build/msvc/readme.txt	2012-05-26 13:51:24 EDT (Sat, 26 May 2012)
@@ -1,4 +1,8 @@
-The provided Microsoft VC++ 10 solution assumes the following commands have been run in the root directory:
+The provided Microsoft VC++ 10 solution assumes the following commands have been run
+in the root directory:
 
      bjam --toolset=msvc-10.0express --build-type=complete --with-filesystem stage
      bjam --toolset=msvc-10.0express --build-type=complete --with-regex stage
+	 
+boost-no-inspect
+ 
Modified: trunk/tools/inspect/inspect.cpp
==============================================================================
--- trunk/tools/inspect/inspect.cpp	(original)
+++ trunk/tools/inspect/inspect.cpp	2012-05-26 13:51:24 EDT (Sat, 26 May 2012)
@@ -1,4 +1,4 @@
-//  inspect program  ---------------------------------------------------------//
+//  inspect program  -------------------------------------------------------------------//
 
 //  Copyright Beman Dawes 2002.
 //  Copyright Rene Rivera 2004-2006.
@@ -15,6 +15,11 @@
 
 //  See http://www.boost.org/tools/inspect/ for more information.
 
+const char* boost_no_inspect = "boost-" "no-inspect";
+
+//  Directories with a file name of the boost_no_inspect value are not inspected.
+//  Files that contain the boost_no_inspect value are not inspected.
+
 
 #include <vector>
 #include <list>
@@ -171,7 +176,7 @@
       // ignore OS X directory info files:
       && leaf != ".DS_Store"
       // ignore if tag file present
-      && !boost::filesystem::exists(pth / "boost-no-inspect")
+      && !boost::filesystem::exists(pth / boost_no_inspect)
       ;
   }
 
@@ -274,9 +279,9 @@
         ++file_count;
         string content;
         load_content( *itr, content );
-        check( lib.empty()
-                ? library_from_content( content ) : lib
-               , *itr, content, insps );
+        if (content.find(boost_no_inspect) == string::npos)
+          check( lib.empty() ? library_from_content( content ) : lib,
+                 *itr, content, insps );
       }
     }
   }
@@ -382,8 +387,6 @@
 
   void display_details()
   {
-    // gps - review this
-
     if (display_text == display_format)
     {
       // display error messages with group indication
@@ -983,10 +986,14 @@
     if (display_text == display_format)
     {
       std::cout << "Details:\n" << inspector_keys;
-    }
+      std::cout << "\nDirectories with a file named \"" << boost_no_inspect << "\" will not be inspected.\n"
+                   "Files containing \"" << boost_no_inspect << "\" will not be inspected.\n";
+   }
     else
     {
       std::cout << "<h2>Details</h2>\n" << inspector_keys;
+      std::cout << "\n<p>Directories with a file named \"" << boost_no_inspect << "\" will not be inspected.<br>\n"
+                   "Files containing \"" << boost_no_inspect << "\" will not be inspected.</p>\n";
     }
     display_details();
   }