mirror of
https://github.com/status-im/PyGithub.git
synced 2026-08-31 19:01:15 +00:00
List matching references (#1471)
This commit is contained in:
@@ -2305,6 +2305,19 @@ class Repository(github.GithubObject.CompletableGithubObject):
|
||||
github.GitRef.GitRef, self._requester, self.url + "/git/refs", None
|
||||
)
|
||||
|
||||
def get_git_matching_refs(self, ref):
|
||||
"""
|
||||
:calls: `GET /repos/:owner/:repo/git/matching-refs/:ref <https://developer.github.com/v3/git/refs/#list-matching-references>`
|
||||
:rtype: :class:`github.PaginatedList.PaginatedList` of :class:`github.GitRef.GitRef`
|
||||
"""
|
||||
assert isinstance(ref, str), ref
|
||||
return github.PaginatedList.PaginatedList(
|
||||
github.GitRef.GitRef,
|
||||
self._requester,
|
||||
self.url + "/git/matching-refs/" + ref,
|
||||
None,
|
||||
)
|
||||
|
||||
def get_git_tag(self, sha):
|
||||
"""
|
||||
:calls: `GET /repos/:owner/:repo/git/tags/:sha <http://developer.github.com/v3/git/tags>`_
|
||||
|
||||
Reference in New Issue
Block a user