~azzar1/unity/add-show-desktop-key

« back to all changes in this revision

Viewing changes to lib/common/svn.py

  • Committer: wagrant
  • Date: 2008-07-16 04:35:05 UTC
  • Revision ID: svn-v3-trunk0:2b9c9e99-6f39-0410-b283-7f802c844ae2:trunk:889
common.svn: Add a method to check if a path has the specified revision.
fileservice_lib: Die if an invalid revision was specified.

Show diffs side-by-side

added added

removed removed

Lines of Context:
41
41
            pass
42
42
    return None
43
43
 
 
44
def revision_exists(client, path, revision):
 
45
    try:
 
46
        client.list(path, revision=revision)
 
47
        return True
 
48
    except pysvn.ClientError:
 
49
        return False
 
50
 
44
51
class PysvnListStatWrapper:
45
52
    '''Wrap a pysvn listing object to look somewhat like a result of
46
53
       os.stat.