Skip to content

Commit 27d8a14

Browse files
committed
docs: updated explanation of the rev parameter for both blame methods
1 parent bbabcdc commit 27d8a14

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

git/repo/base.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -963,7 +963,9 @@ def blame_incremental(self, rev: str | HEAD | None, file: str, **kwargs: Any) ->
963963
Unlike :meth:`blame`, this does not return the actual file's contents, only a
964964
stream of :class:`BlameEntry` tuples.
965965
966-
:param rev: Revision specifier, see git-rev-parse for viable options.
966+
:param rev: Revision specifier. If `None`, the blame will include all the latest
967+
uncommitted changes. Otherwise, anything succesfully parsed by git-rev-parse
968+
is a valid option.
967969
968970
:return: Lazy iterator of :class:`BlameEntry` tuples, where the commit indicates
969971
the commit to blame for the line, and range indicates a span of line numbers
@@ -1053,7 +1055,9 @@ def blame(
10531055
) -> List[List[Commit | List[str | bytes] | None]] | Iterator[BlameEntry] | None:
10541056
"""The blame information for the given file at the given revision.
10551057
1056-
:param rev: Revision specifier, see git-rev-parse for viable options.
1058+
:param rev: Revision specifier. If `None`, the blame will include all the latest
1059+
uncommitted changes. Otherwise, anything succesfully parsed by git-rev-parse
1060+
is a valid option.
10571061
10581062
:return:
10591063
list: [git.Commit, list: [<line>]]

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy