Created
October 29, 2015 01:15
-
-
Save 0x27/9622f684c03ecc101ec8 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python | |
# coding: utf-8 | |
# ~ skyhighatrist | |
import svn.remote | |
import sys | |
def dump(plugin_base): | |
r = svn.remote.RemoteClient(plugin_base) | |
num_items = len(list(r.list())) | |
idx = 0 | |
for repo_path in r.list(): | |
plugin_repo = plugin_base + repo_path | |
try: | |
print "{+} Now grabbing %s" %(plugin_repo) | |
s = svn.remote.RemoteClient(plugin_repo) | |
s.checkout("./%s" %(repo_path)) | |
except Exception, e: | |
print e | |
idx = idx+1 | |
print "{$} Now on %d of %d items!" %(idx, num_items) | |
def main(args): | |
if len(args) != 2: | |
sys.exit("use: %s http://svn.org.com/" %(args[0])) | |
dump(plugin_base=args[1]) | |
if __name__ == "__main__": | |
main(args=sys.argv) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment