libvcs.sync.svn#

For subversion, aka svn(1)

Tool to manage a local SVN (Subversion) working copy from a repository.

exception libvcs.sync.svn.SvnUrlRevFormattingError(data, *args)[source]#

Bases: ValueError

Raised when SVN Revision output is not in the expected format.

Parameters:
class libvcs.sync.svn.SvnSync(*, url, dir, **kwargs)[source]#

Bases: BaseSync

Tool to manage a local SVN (Subversion) working copy from a SVN repository.

Working copy of a SVN repository.

Parameters:
  • url (str) – URL in subversion repository

  • username (str, optional) – username to use for checkout and update

  • password (str, optional) – password to use for checkout and update

  • svn_trust_cert (bool) – trust the Subversion server site certificate, default False

  • dir (Path) –

  • kwargs (Any) –

bin_name: str = 'svn'#

VCS app name, e.g. β€˜git’

schemes: tuple[str, ...] = ('svn', 'svn+ssh', 'svn+http', 'svn+https', 'svn+svn')#

List of supported schemes to register in urlparse.uses_netloc

__init__(*, url, dir, **kwargs)[source]#

Working copy of a SVN repository.

Parameters:
  • url (str) – URL in subversion repository

  • username (str, optional) – username to use for checkout and update

  • password (str, optional) – password to use for checkout and update

  • svn_trust_cert (bool) – trust the Subversion server site certificate, default False

  • dir (str | PathLike[str]) –

  • kwargs (Any) –

Return type:

None

cmd: Svn#
_user_pw_args()[source]#
Return type:

list[Any]

obtain(quiet=None, *args, **kwargs)[source]#

Check out a working copy from a SVN repository.

Return type:

None

Parameters:
  • quiet (bool | None) –

  • args (Any) –

  • kwargs (Any) –

get_revision_file(location)[source]#

Return revision for a file.

Return type:

int

Parameters:

location (str) –

get_revision(location=None)[source]#

Return maximum revision for all files under a given location.

Return type:

int

Parameters:

location (str | None) –

update_repo(dest=None, *args, **kwargs)[source]#

Fetch changes from SVN repository to local working copy.

Return type:

None

Parameters:
  • dest (str | None) –

  • args (Any) –

  • kwargs (Any) –

classmethod _get_svn_url_rev(location)[source]#
Return type:

tuple[Optional[str], int]

Parameters:

location (str) –