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

Method write

pygit2/repository.py:142–148  ·  view source on GitHub ↗

write(type, data) -> Oid Write raw object data into the repository. First arg is the object type, the second one a buffer with data. Return the Oid of the created object.

(self, type: int, data: bytes | str)

Source from the content-addressed store, hash-verified

140 return self.odb.read(oid)
141
142 def write(self, type: int, data: bytes | str) -> Oid:
143 """write(type, data) -> Oid
144
145 Write raw object data into the repository. First arg is the object
146 type, the second one a buffer with data. Return the Oid of the created
147 object."""
148 return self.odb.write(type, data)
149
150 def pack(
151 self,

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected