Index: /anuga_core/source/anuga/utilities/data_audit.py
===================================================================
--- /anuga_core/source/anuga/utilities/data_audit.py	(revision 5017)
+++ /anuga_core/source/anuga/utilities/data_audit.py	(revision 5018)
@@ -1,3 +1,5 @@
-"""Track IP of data files included in this distribution. 
+"""Track IP of data files in an entire directory tree.
+See docstring for the public function IP_verified()
+for details.
 """
 
@@ -7,7 +9,4 @@
 from anuga.utilities.xml_tools import xml2object, XML_element
 from anuga.utilities.system_tools import compute_checksum
-
-from data_audit_config import extensions_to_ignore, directories_to_ignore, files_to_ignore
-
 
 
@@ -25,5 +24,10 @@
                     WrongTags)
 
-def IP_verified(directory, verbose=False):
+
+def IP_verified(directory,
+                extensions_to_ignore=None,
+                directories_to_ignore=None,
+                files_to_ignore=None,
+                verbose=False):
     """Find and audit potential data files that might violate IP
 
@@ -41,6 +45,15 @@
     If verbose is False, only diagnostics about failed audits will appear.
     All files that check OK will pass silently.
-    
-
+
+    Optional arguments extensions_to_ignore, directories_to_ignore, and
+    files_to_ignore are lists of things to skip.
+
+    Examples are:
+    extensions_to_ignore = ['.py','.c','.h', '.f'] # Ignore source code
+    files_to_ignore = ['README.txt']
+    directories_to_ignore = ['.svn', 'misc']
+
+    None is also OK for these parameters.
+    
     """
 
@@ -51,5 +64,8 @@
     first_time = True
     all_files_accounted_for = True
-    for dirpath, datafile in identify_datafiles(directory):
+    for dirpath, datafile in identify_datafiles(directory,
+                                                extensions_to_ignore,
+                                                directories_to_ignore,
+                                                files_to_ignore):
         
         filename = join(dirpath, datafile)
@@ -99,6 +115,15 @@
 
 
-def identify_datafiles(root):
+
+#------------------
+# Private functions
+#------------------
+def identify_datafiles(root,
+                       extensions_to_ignore=None,
+                       directories_to_ignore=None,
+                       files_to_ignore=None):
     """ Identify files that might contain data
+
+    See function IP_verified() for details about optinoal parmeters
     """
 
@@ -109,6 +134,4 @@
                 dirnames.remove(ignore)  # don't visit ignored directories
 
-        #print 'Searching dir', dirpath
-        
 
         for filename in filenames:
@@ -129,5 +152,16 @@
 
 def license_file_is_valid(fid, dirpath='.', verbose=False):
-    """Check that XML license file is valid
+    """Check that XML license file is valid.
+
+    Check for each datafile listed that
+
+    * Datafile tags are there
+    * Fields are non empty
+    * Datafile exists
+    * Checksum is correct
+    * Datafile is flagged as publishable
+
+    If anything is violated an appropriate exception is raised.
+    If everything is honky dory the function will return True.
     """
 
@@ -149,4 +183,7 @@
 
     # Validate elements: metadata, datafile, datafile, ...
+    # FIXME (Ole): I'd like this to verified by the parser
+    # using a proper DTD template one day....
+    # For not, let's check the main ones.
     elements = doc['ga_license_file']
     if not elements.has_key('metadata'):
@@ -174,4 +211,7 @@
     author = metadata['author']
     if verbose: print 'Author:   ', author
+    if author == '':
+        msg = 'Missing author'
+        raise Exception, msg                
     
     #svn_keywords = metadata['svn_keywords']
Index: uga_core/source/anuga/utilities/data_audit_config.py
===================================================================
--- /anuga_core/source/anuga/utilities/data_audit_config.py	(revision 5017)
+++ 	(revision )
@@ -1,29 +1,0 @@
-"""Specify what extensions, directories and files should be ignored by
-the data_audit process.
-
-These will generally be specific to the software project.
-"""
-
-
-# Ignore source code files
-extensions_to_ignore = ['.py','.c','.h', '.f'] #, '.gif', '.jpg', '.png']
-
-# Ignore generated stuff 
-extensions_to_ignore += ['.pyc', '.o', '.so', '~']
-extensions_to_ignore += ['.aux', '.log', '.idx', 'ilg', '.ind',
-                         '.bbl', '.blg']
-
-# Ignore license files themselves
-extensions_to_ignore += ['.lic']    
-
-
-# Ignore certain other files
-files_to_ignore = ['README.txt']
-
-# Ignore directories
-directories_to_ignore = ['anuga_work', 'pymetis', 'obsolete_code',
-                         'anuga_parallel', 'anuga_viewer',
-                         'planning', 'coding_standards',
-                         'experimentation',
-                         '.svn', 'misc', '.metadata']
-
Index: /anuga_core/source/anuga/utilities/data_audit_wrapper.py
===================================================================
--- /anuga_core/source/anuga/utilities/data_audit_wrapper.py	(revision 5018)
+++ /anuga_core/source/anuga/utilities/data_audit_wrapper.py	(revision 5018)
@@ -0,0 +1,44 @@
+"""Wrapper around data_audit.
+
+This wrapper is specific to ANUGA.
+
+This wrapper will run the
+
+Specify what extensions, directories and files should be ignored by
+the data_audit process.
+
+These will generally be specific to each software project.
+"""
+
+from data_audit import IP_verified as IP_engine
+
+# Ignore source code files
+extensions_to_ignore = ['.py','.c','.h', '.f', '.bat']
+
+# Ignore generated stuff 
+extensions_to_ignore += ['.pyc', '.o', '.so', '~']
+extensions_to_ignore += ['.aux', '.log', '.idx', 'ilg', '.ind',
+                         '.bbl', '.blg']
+
+# Ignore license files themselves
+extensions_to_ignore += ['.lic']    
+
+
+# Ignore certain other files,
+files_to_ignore = ['README.txt', 'LICENSE.txt', 'Makefile',
+                   '.temp', 'SConstruct', 'SConscript']
+
+# Ignore directories
+directories_to_ignore = ['.svn', 'misc', '.metadata']
+
+
+
+def IP_verified(directory, verbose=False):
+
+    result = IP_engine(directory,
+                       extensions_to_ignore,
+                       directories_to_ignore,
+                       files_to_ignore,
+                       verbose=verbose)    
+    return result
+    
Index: /anuga_core/test_all.py
===================================================================
--- /anuga_core/test_all.py	(revision 5017)
+++ /anuga_core/test_all.py	(revision 5018)
@@ -1,3 +1,3 @@
-from anuga.utilities.data_audit import IP_verified
+from anuga.utilities.data_audit_wrapper import IP_verified
 from tempfile import mktemp
 
@@ -14,4 +14,17 @@
 
 
+print
+print '************************** NOTE *************************************'
+print 'If all unit tests passed you should run the suite of validation tests'
+print 'Go to the directory anuga_validation/automated_validation_tests'
+print 'and run'
+print '    python validate_all.py'
+print
+print 'These tests will take a few hours and will verify that ANUGA'
+print 'produces the physical results expected.'
+print '*********************************************************************'
+
+
+
 # Temporary bail out
 import sys; sys.exit() 
@@ -23,9 +36,18 @@
 
 # Create temporary area for svn to export source files
+# FIXME (Ole): It would be good to make sure these files
+# are exactly the same as those walked over by the
+# release script: create_distribution.
+#
+# Come to think of it - this is probably not the best
+# place for this check. It may have to move up one level.
+# What do you all think?
+
+
+
 temp_dir = mktemp()
 
 print 'Temp dir', temp_dir
 os.mkdir(temp_dir)
-
 
 # Get the ANUGA core source files
@@ -42,14 +64,5 @@
 
 
-print
-print '************************** NOTE *************************************'
-print 'If all unit tests passed you should run the suite of validation tests'
-print 'Go to the directory anuga_validation/automated_validation_tests'
-print 'and run'
-print '    python validate_all.py'
-print
-print 'These tests will take a few hours and will verify that ANUGA'
-print 'produces the physical results expected.'
-print '*********************************************************************'
+
 
     
Index: /create_distribution.py
===================================================================
--- /create_distribution.py	(revision 5017)
+++ /create_distribution.py	(revision 5018)
@@ -18,5 +18,5 @@
    it depends on still work for that revision.
 
-   This script works only on Linux
+   This script works only on Linux!
 """
 
@@ -30,5 +30,5 @@
 from anuga.config import major_revision
 
-from anuga.utilities.data_audit import IP_verified
+from anuga.utilities.data_audit_wrapper import IP_verified
 
 if platform == 'win32':
