Update of /cvsroot/cppunit/cppunit/devtools
In directory sc8-pr-cvs4.sourceforge.net:/tmp/cvs-serv15857/devtools
Added Files:
cvs-root-update.py
Log Message:
* added simple script to update cvs root (handle new sourceforge cvs server naming)
--- NEW FILE: cvs-root-update.py ---
# Explore directory recursively and replace cvs root for access by the specified developper.
# Put together by a newbie to python, use at your own risk!
import os
import sys
def updateCVSRoot( developper, dirName, fileNames ):
print "Exploring: ", os.path.abspath( dirName )
if ( fileNames.count( 'Root' ) > 0 ) and os.path.basename(dirName) == 'CVS':
cvsroot_path = os.path.join( dirName, 'Root' )
new_root = ':ext:%s...@cp...:/cvsroot/cppunit' % developper
file( cvsroot_path, 'wt' ).write( new_root )
print 'Updated:', cvsroot_path
if __name__ == '__main__':
developper = sys.argv[1]
os.path.walk( ".", updateCVSRoot, developper )
|