Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 10 additions & 3 deletions git/cmd.py
Original file line number Diff line number Diff line change
Expand Up @@ -1119,9 +1119,16 @@ def execute(
information (stdout).

:param command:
The command argument list to execute.
It should be a sequence of program arguments, or a string. The
program to execute is the first item in the args sequence or string.
The command to execute. A sequence of program arguments is the
recommended form when `shell` is ``False`` (the default), e.g.
``["git", "log", "-n", "1"]``.

A string is accepted, but with `shell` set to ``False`` it is passed
as a single executable name to :class:`subprocess.Popen`. For example,
``"git log -n 1"`` looks for an executable literally named
``git log -n 1`` and will fail with :class:`GitCommandNotFound`. To
split a command string into argv tokens, pass ``shlex.split(...)`` as
a sequence or set `shell` to ``True`` (see the warning below).

:param istream:
Standard input filehandle passed to :class:`subprocess.Popen`.
Expand Down
Loading