[Python-checkins] python/dist/src/Doc/tools prechm.py,1.5,1.6
tim_one@sourceforge.net
tim_one@sourceforge.net
Fri, 19 Apr 2002 19:37:09 -0700
Update of /cvsroot/python/python/dist/src/Doc/tools
In directory usw-pr-cvs1:/tmp/cvs-serv4375
Modified Files:
prechm.py
Log Message:
do_project(): Modernized the code.
Index: prechm.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Doc/tools/prechm.py,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** prechm.py 20 Apr 2002 02:07:58 -0000 1.5
--- prechm.py 20 Apr 2002 02:37:07 -0000 1.6
***************
*** 302,313 ****
output.write(contents_footer)
!
! def do_project( library, output, arch, version) :
output.write(project_template % locals())
! for book in library :
! for page in os.listdir(book[0]) :
! if page[string.rfind(page, '.'):] == '.html' or \
! page[string.rfind(page, '.'):] == '.css':
! output.write(book[0]+ '\\' + page + '\n')
--- 302,316 ----
output.write(contents_footer)
! # Fill in the [FILES] section of the project (.hhp) file.
! # 'library' is the list of directory description tuples from
! # supported_libraries for the version of the docs getting generated.
! def do_project(library, output, arch, version):
output.write(project_template % locals())
! for book in library:
! directory = book[0]
! path = directory + '\\%s\n'
! for page in os.listdir(directory):
! if page.endswith('.html') or page.endswith('.css'):
! output.write(path % page)
***************
*** 386,389 ****
if __name__ == '__main__' :
do_it()
-
-
--- 389,390 ----