Tim Hatch

Weblog | Photos | Projects | Panoramas | About

vcslib

Currently supports git and subversion, you give it a repo location, path within the repository, and a revision id, you can get the data.

>>> from vcslib import get_vcs_layer
>>> svn = get_vcs_layer('svn')
>>> print svn.get_file_contents('http://svn.python.org/projects/peps/trunk',
...                             75957, 'pep-0001.txt')
PEP: 1
Title: PEP Purpose and Guidelines
...

Supports

  • SVN (repo path can be a working copy, file:// repo or http:// repo, including sub-repo paths)
  • Git (repo path must be local; .git inferred automatically, if repository isn't bare)
  • Hg (repo path must be local)

Downloads

Direct source access at git://code.timhatch.com/vcslib.git

Contributing

I welcome patches, suggestions, and bugreports. Send me an email to code@timhatch.com