#!/usr/bin/env python import sys, os, subprocess import git_repos TOOLS_DIR = os.path.join( sys.path[0], "../" ) # Perform the svn up print "Updating subversion...", sys.stdout.flush() p = subprocess.Popen( "svn up -q", cwd = TOOLS_DIR, shell = True ) p.communicate() p.wait() print "done." # Git up # Make the git dir if it's not there if not os.path.exists( os.path.join(TOOLS_DIR, "git") ): os.mkdir( os.path.join(TOOLS_DIR, "git") ) print "Updating git repos:" git_repos.update_all( TOOLS_DIR )