Skip to content

Commit fc59e5e

Browse files
committed
Improve stream_object_data and _parse_object_header docstrings
This slightly adjusts working and formatting of these methods of the Git class, for clarity.
1 parent c0a27c0 commit fc59e5e

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

Diff for: git/cmd.py

+4-2
Original file line numberDiff line numberDiff line change
@@ -1491,7 +1491,9 @@ def _call_process(
14911491
def _parse_object_header(self, header_line: str) -> Tuple[str, str, int]:
14921492
"""
14931493
:param header_line:
1494-
<hex_sha> type_string size_as_int
1494+
A line of the form::
1495+
1496+
<hex_sha> type_string size_as_int
14951497
14961498
:return:
14971499
(hex_sha, type_string, size_as_int)
@@ -1581,7 +1583,7 @@ def get_object_data(self, ref: str) -> Tuple[str, str, int, bytes]:
15811583
return (hexsha, typename, size, data)
15821584

15831585
def stream_object_data(self, ref: str) -> Tuple[str, str, int, "Git.CatFileContentStream"]:
1584-
"""Similar to :meth:`get_object_header`, but returns the data as a stream.
1586+
"""Similar to :meth:`get_object_data`, but returns the data as a stream.
15851587
15861588
:return:
15871589
(hexsha, type_string, size_as_int, stream)

0 commit comments

Comments
 (0)