◐ Shell
reader mode source ↗
Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
File filter
Conversations
Jump to
Diff view
Apply and reload
Show whitespace
Diff view
Apply and reload
24 changes: 12 additions & 12 deletions git/repo/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -485,15 +485,15 @@ def tree(self, rev=None):
def iter_commits(self, rev=None, paths='', **kwargs):
"""A list of Commit objects representing the history of a given ref/commit

:parm rev:
revision specifier, see git-rev-parse for viable options.
If None, the active branch will be used.

:parm paths:
is an optional path or a list of paths to limit the returned commits to
Commits that do not contain that path or the paths will not be returned.

:parm kwargs:
Arguments to be passed to git-rev-list - common ones are
max_count and skip

Expand Down Expand Up @@ -585,7 +585,7 @@ def _get_alternates(self):
def _set_alternates(self, alts):
"""Sets the alternates

:parm alts:
is the array of string paths representing the alternates at which
git should look for objects, i.e. /home/user/repo/.git/objects

Expand Down Expand Up @@ -695,7 +695,7 @@ def blame_incremental(self, rev, file, **kwargs):
Unlike .blame(), this does not return the actual file's contents, only
a stream of BlameEntry tuples.

:parm rev: revision specifier, see git-rev-parse for viable options.
:return: lazy iterator of BlameEntry tuples, where the commit
indicates the commit to blame for the line, and range
indicates a span of line numbers in the resulting file.
Expand Down Expand Up @@ -757,7 +757,7 @@ def blame_incremental(self, rev, file, **kwargs):
def blame(self, rev, file, incremental=False, **kwargs):
"""The blame information for the given file at the given revision.

:parm rev: revision specifier, see git-rev-parse for viable options.
:return:
list: [git.Commit, list: [<line>]]
A list of tuples associating a Commit object with a list of lines that
Expand Down Expand Up @@ -871,7 +871,7 @@ def init(cls, path=None, mkdir=True, odbt=GitCmdObjectDB, expand_vars=True, **kw
or None in which case the repository will be created in the current
working directory

:parm mkdir:
if specified will create the repository directory if it doesn't
already exists. Creates the directory with a mode=0755.
Only effective if a path is explicitly given
Expand All @@ -886,7 +886,7 @@ def init(cls, path=None, mkdir=True, odbt=GitCmdObjectDB, expand_vars=True, **kw
can lead to information disclosure, allowing attackers to
access the contents of environment variables

:parm kwargs:
keyword arguments serving as additional options to the git-init command

:return: ``git.Repo`` (the newly created repo)"""
Expand Up @@ -984,10 +984,10 @@ def clone_from(cls, url, to_path, progress=None, env=None, **kwargs):
def archive(self, ostream, treeish=None, prefix=None, **kwargs):
"""Archive the tree at the given revision.

:parm ostream: file compatible stream object to which the archive will be written as bytes
:parm treeish: is the treeish name/id, defaults to active branch
:parm prefix: is the optional prefix to prepend to each filename in the archive
:parm kwargs: Additional arguments passed to git-archive

* Use the 'format' argument to define the kind of format. Use
specialized ostreams to write any format supported by python.
Expand Down
4 changes: 2 additions & 2 deletions git/util.py
Original file line number Diff line number Diff line change
Expand Up @@ -802,11 +802,11 @@ class BlockingLockFile(LockFile):
def __init__(self, file_path, check_interval_s=0.3, max_block_time_s=MAXSIZE):
"""Configure the instance

:parm check_interval_s:
Period of time to sleep until the lock is checked the next time.
By default, it waits a nearly unlimited time

:parm max_block_time_s: Maximum amount of seconds we may lock"""
super(BlockingLockFile, self).__init__(file_path)
self._check_interval = check_interval_s
self._max_block_time = max_block_time_s
Expand Down
Toggle all file notes Toggle all file annotations