MCPcopy Create free account
hub / github.com/libgit2/pygit2 / PushUpdate

Class PushUpdate

pygit2/remotes.py:84–109  ·  view source on GitHub ↗

Represents an update which will be performed on the remote during push.

Source from the content-addressed store, hash-verified

82
83
84class PushUpdate:
85 """
86 Represents an update which will be performed on the remote during push.
87 """
88
89 src_refname: str
90 """The source name of the reference"""
91
92 dst_refname: str
93 """The name of the reference to update on the server"""
94
95 src: Oid
96 """The current target of the reference"""
97
98 dst: Oid
99 """The new target for the reference"""
100
101 def __init__(self, c_struct: Any) -> None:
102 src_refname = maybe_string(c_struct.src_refname)
103 dst_refname = maybe_string(c_struct.dst_refname)
104 assert src_refname is not None, 'libgit2 returned null src_refname'
105 assert dst_refname is not None, 'libgit2 returned null dst_refname'
106 self.src_refname = src_refname
107 self.dst_refname = dst_refname
108 self.src = Oid(raw=bytes(ffi.buffer(c_struct.src.id)[:]))
109 self.dst = Oid(raw=bytes(ffi.buffer(c_struct.dst.id)[:]))
110
111
112class TransferProgress:

Callers 1

_push_negotiation_cbFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…