mirror of
https://github.com/beetbox/beets.git
synced 2025-12-28 11:32:30 +01:00
document util.command_output return value change
After commit `30395911 util.command_output: return stderr, too`, `command_output` returns a tuple of stdout and stderr. Document that change by adding a changelog entry and add a usage note to `command_output`'s docstring.
This commit is contained in:
parent
30395911e2
commit
45aa75a4ef
2 changed files with 5 additions and 1 deletions
|
|
@ -805,7 +805,8 @@ CommandOutput = namedtuple("CommandOutput", ("stdout", "stderr"))
|
|||
def command_output(cmd, shell=False):
|
||||
"""Runs the command and returns its output after it has exited.
|
||||
|
||||
Returns a CommandOutput.
|
||||
Returns a CommandOutput. The attributes ``stdout`` and ``stderr`` contain
|
||||
byte strings of the respective output streams.
|
||||
|
||||
``cmd`` is a list of arguments starting with the command names. The
|
||||
arguments are bytes on Unix and strings on Windows.
|
||||
|
|
|
|||
|
|
@ -74,6 +74,9 @@ For plugin developers:
|
|||
is almost identical apart from the name change. Again, we'll re-export at the
|
||||
old location (with a deprecation warning) for backwards compatibility, but
|
||||
might stop doing this in a future release.
|
||||
* ``beets.util.command_output`` now returns a named tuple of stdout and stderr
|
||||
instead of only returning stdout. stdout can be accessed as a simple
|
||||
attribute.
|
||||
|
||||
For packagers:
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue