#!/usr/bin/python import sys import subprocess def clonePackage(base, pkg): # Use --no-follow-parent because we're going to handle that with # grafts. subprocess.check_call(['git', 'svn', 'clone', '--no-follow-parent', '%s/packages/%s' % (base, pkg)], stdout=subprocess.PIPE) def cloneAllPackages(base): for pkg in open('package-list'): clonePackage(base, pkg.strip()) if __name__ == '__main__': try: base = sys.argv[1] except: base = 'svn://invirt.mit.edu/trunk' cloneAllPackages(base)