bridge.services.protocols.repo_provider module#
Protocol for repository operations and a minimal ForkInfo dataclass.
- class bridge.services.protocols.repo_provider.ForkInfo(full_name, owner, repo)[source]#
Bases:
objectGeneric metadata for a forked repository.
- Parameters:
full_name (str)
owner (str)
repo (str)
-
full_name:
str= <dataclasses._MISSING_TYPE object>#
-
owner:
str= <dataclasses._MISSING_TYPE object>#
-
repo:
str= <dataclasses._MISSING_TYPE object>#
- class bridge.services.protocols.repo_provider.RepoProvider(*args, **kwargs)[source]#
Bases:
ProtocolProtocol for repository operations.
- apply_changes_and_push(repo_path, branch_name, file_changes)[source]#
Apply file changes and push to a branch.
- Parameters:
repo_path (str)
branch_name (str)
file_changes (dict)
- clone_context(repo_full_name)[source]#
Use context manager to clone a repository.
- Return type:
AbstractContextManager[str]- Parameters:
repo_full_name (str)
- async create_issue(owner, repo, title, body='', labels=None, assignees=None)[source]#
Create a new issue on a repository.
- Return type:
dict- Parameters:
owner (str)
repo (str)
title (str)
body (str)
labels (list[str] | None)
assignees (list[str] | None)