In Subversion's documentation there's an example of using Subversion from Python
#!/usr/bin/python
import svn.fs, svn.core, svn.reposdef crawl_filesystem_dir(root, directory):"""Recursively crawl DIRECTORY under ROOT in the filesystem, and return a list of all the paths at or below DIRECTORY."""# Get the directory entries for DIRECTORY.entries = svn.fs.svn_fs_dir_entries(root, directory)
When I run this code I get an import error:
$ python crawl.py
Traceback (most recent call last):File "crawl.py", line 7, in <module>import svn.fs, svn.core, svn.repos
ImportError: No module named svn.fs
This means I'm missing the library svn
. I tried to install the package, but the Python package manager can't find it.
$ pip install svn
Downloading/unpacking svnCould not find any downloads that satisfy the requirement svn
No distributions at all found for svn
So, how do I install this library?