Skip to content

Instantly share code, notes, and snippets.

@0x27
Created October 29, 2015 01:15
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save 0x27/9622f684c03ecc101ec8 to your computer and use it in GitHub Desktop.
Save 0x27/9622f684c03ecc101ec8 to your computer and use it in GitHub Desktop.
#!/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