Skip to main content

svine

Lightweight Python wrapper for a highly limited number of svn subcommands. Meant for use in mining Subversion repositories.

Installation

pip install svine

Usage

Setup for all use cases is the same:

from svine import SvnClient, SvnException

remote = SvnClient("https://svn.repository.url/whoever/still/uses/svn/")

svn log

Returns log entries in named tuples with fields for message (msg), author, revision and date.

try:
    for log_entry in remote.log():
        print(log_entry.msg)
except SvnException:
    # Handle
    pass

# Get latest log entry only
try:
    for log_entry in remote.log(limit=1):
        print(log_entry.author)
except SvnException:
    # Handle
    pass

svn info

Provides a named tuple with the info returned by the svn info subcommand. Fields are: "url", "relative_url", "entry_kind", "entry_path", "entry_revision", "repository_root", "repository_uuid", "wcinfo_wcroot_abspath", "wcinfo_schedule", "wcinfo_depth", "commit_author", "commit_date", "commit_revision".

try:
    info = remote.info()
    print(info.repository_root)
except SvnException:
    # Handle
    pass

svn list

Yields the contents only of the remote repository root directory.

try:
    for root_content in remote.list():
        print(root_content)
except SvnException:
    # Handle
    pass

# Prints, e.g.:
# 
# trunk/
# branches/
# tags/

Contributing

Contributions are generally welcome. Please open an issue to start the contribution process.

Please note that there are currently no plans or dedicated resources to do development or maintenance of this project.

Licenses

This project is compliant with the REUSE Specifications version 3.2. Applicable licenses are defined in REUSE.toml and the respective license texts are available in LICENSES/.

Metadata

Release files for svine 0.2.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for svine 0.2.1
File Size Uploaded
svine-0.2.1.tar.gz 13.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for svine 0.2.1
File Interpreter ABI Platform
svine-0.2.1-py3-none-any.whl Python 3 none any Details

Total release size: 27.5 kB

Release files / svine-0.2.1.tar.gz

Download URL svine-0.2.1.tar.gz
Size 13.2 kB
Tags Source
SHA-256 checksum
How to use checksums
6999019f675fde8e1b36218012e22c7860b8dff89665c9f1d84af9cb58b55d97
BLAKE2b-256 checksum
How to use checksums
4001aff1625d4880693578decf1cb1aa1be58407ed7d180bd2601b6826d69a66
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.8.22

Release files / svine-0.2.1-py3-none-any.whl

Download URL svine-0.2.1-py3-none-any.whl
Size 14.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
07df6c17de431c4faf573df64eee68ac5931f14a287ab64847ace485926fec97
BLAKE2b-256 checksum
How to use checksums
cbc3927ec5c8e96a3beb86bd5ab0199806275784ef1fa0b45689921345bca47c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.8.22

Release history Release notifications | RSS feed

This release

0.2.1 This release

2 release files

0.2.0

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page