예제 #1
0
 def createClassList(self, filesDir, docsDir):
     """Create an HTML class hierarchy listing of the source files."""
     from DocSupport.ClassList import ClassList
     name = filesDir.replace('/', '.')
     self.printMsg('Creating class list of %s...' % name)
     classlist = ClassList(name)
     filesDir, subDir = (filesDir + '/').split('/', 1)
     saveDir = os.getcwd()
     os.chdir(filesDir)
     try:
         classlist.readFiles(subDir + '*.py')
         targetName = docsDir + '/ClassList.html'
         self.printMsg('Creating %s...' % targetName)
         classlist.printForWeb(False, '../' + targetName)
         targetName = docsDir + '/ClassHierarchy.html'
         self.printMsg('Creating %s...' % targetName)
         classlist.printForWeb(True, '../' + targetName)
     finally:
         os.chdir(saveDir)