def svn_repo(repo):
    """
    Tests if a repo URL is a svn repo, then returns the repo url.
    """

    # we can just go for known providers of svn
    services = ('svn://', 'https://svn.code.sf.net/p/', 'http://svn.savannah.gnu.org/svn/', 'https://svn.icculus.org/', 'http://svn.icculus.org/', 'http://svn.uktrainsim.com/svn/', 'https://rpg.hamsterrepublic.com/source/wip')
    if any(repo.startswith(service) for service in services):
        return repo

    # not svn
    return None