Package pybaz :: Module _output
[frames] | no frames]

Module _output

source code


Internal module providing output parsing functionality.

This module implements some of public interface for the
pybaz_ package. But for convenience reasons the author prefers
to store this code in a file separate from ``__init__.py``.

.. _pybaz: arch-module.html

This module is strictly internal and should never be used.



Classes
  Chatter
Chatter lines in ``tla`` output.
  MergeOutcome
Abstract base class for changeset application summary output lines.
  TreeChange
Abstract base class for ``changes`` summary output lines.
  FileAddition
Changeset summary line for a new file.
  FileDeletion
Changeset summary line for a deleted file.
  FileModification
Changeset summary line for file whose contents were modified.
  FilePermissionsChange
Changeset summary line for a change in permissions.
  FileRename
Changeset summary line for a renaming.
  SymlinkModification
Changeset summary line for a symlink modification.
  PatchConflict
Changeset application summary line for a patch conflict.
Functions
 
classify_chatter(iter)
Classify chatter in a sequence of strings.
 
classify_changeset_creation(lines, pad=' ')
Classify the output of a changeset creation command.
 
classify_changeset_application(lines)
Classify the output of a change-producing command.
Function Details

classify_chatter(iter)

 
Classify chatter in a sequence of strings.

Generator that yields Chatter objects for chatter lines, and
yields other lines verbatim.

:param iter: iterable of str
:rtype: iterable of `Chatter` or str

classify_changeset_creation(lines, pad=' ')

 
Classify the output of a changeset creation command.

:param lines: incremental output from a changeset creation command.
:type lines: iterator of str
:param pad: padding text between prefix and file name.
:type pad: str
:rtype: Iterable of `Chatter`, `TreeChange`, str

:note: diff output (*e.g.* ``changes --diffs``) is not supported.

classify_changeset_application(lines)

 
Classify the output of a change-producing command.

:param lines: incremental output from a changeset application command.
:type lines: iterable of str
:rtype: iterable of `Chatter`, `MergeOutcome`, str

:note: diff output (*e.g.* ``changes --diffs``) is not supported.