diff options
Diffstat (limited to '3rdparty/portaudio/doc/utils/checkfiledocs.py')
-rw-r--r-- | 3rdparty/portaudio/doc/utils/checkfiledocs.py | 18 |
1 files changed, 14 insertions, 4 deletions
diff --git a/3rdparty/portaudio/doc/utils/checkfiledocs.py b/3rdparty/portaudio/doc/utils/checkfiledocs.py index 857eaf945ea..5d6b58518f7 100644 --- a/3rdparty/portaudio/doc/utils/checkfiledocs.py +++ b/3rdparty/portaudio/doc/utils/checkfiledocs.py @@ -18,14 +18,23 @@ paHtmlDocDirectory = os.path.join( paRootDirectory, "doc", "html" ) ## This can be used as a first-level check to make sure the documentation is in order. ## ## The idea is to get a list of which files are missing doxygen documentation. +## +## How to run: +## $ cd doc/utils +## $ python checkfiledocs.py +def oneOf_a_in_b(a, b): + for x in a: + if x in b: + return True + return False # recurse from top and return a list of all with the given # extensions. ignore .svn directories. return absolute paths -def recursiveFindFiles( top, extensions, includePaths ): +def recursiveFindFiles( top, extensions, dirBlacklist, includePaths ): result = [] for (dirpath, dirnames, filenames) in os.walk(top): - if not '.svn' in dirpath: + if not oneOf_a_in_b(dirBlacklist, dirpath): for f in filenames: if os.path.splitext(f)[1] in extensions: if includePaths: @@ -41,8 +50,9 @@ def doxygenHtmlDocFileName( sourceFile ): return sourceFile.replace( '_', '__' ).replace( '.', '_8' ) + '.html' -sourceFiles = recursiveFindFiles( paRootDirectory, [ '.c', '.h', '.cpp' ], True ); -docFiles = recursiveFindFiles( paHtmlDocDirectory, [ '.html' ], False ); +sourceFiles = recursiveFindFiles( os.path.join(paRootDirectory,'src'), [ '.c', '.h', '.cpp' ], ['.svn', 'mingw-include'], True ); +sourceFiles += recursiveFindFiles( os.path.join(paRootDirectory,'include'), [ '.c', '.h', '.cpp' ], ['.svn'], True ); +docFiles = recursiveFindFiles( paHtmlDocDirectory, [ '.html' ], ['.svn'], False ); |