b.v.VersionInfoBuilder(object) : class documentation

Part of bzrlib.version_info_formats View In Hierarchy

Known subclasses: bzrlib.tests.test_version_info.TestBuilder, bzrlib.version_info_formats.format_custom.CustomVersionInfoBuilder, bzrlib.version_info_formats.format_python.PythonVersionInfoBuilder, bzrlib.version_info_formats.format_rio.RioVersionInfoBuilder

A class which lets you build up information about a revision.
Method __init__ Build up information about the given branch.
Method generate Output the version information to the supplied file.
Method _extract_file_revisions Extract the working revisions for all files
Method _iter_revision_history Find the messages for all revisions in history.
Method _get_revision_id Get the revision id we are working on.
Method _get_revno_str Undocumented
def __init__(self, branch, working_tree=None, check_for_clean=False, include_revision_history=False, include_file_revisions=False, template=None, revision_id=None):
Build up information about the given branch. If working_tree is given, it can be checked for changes.
ParametersbranchThe branch to work on
working_treeIf supplied, preferentially check the working tree for changes.
check_for_cleanIf False, we will skip the expense of looking for changes.
include_revision_historyIf True, the output will include the full mainline revision history, including date and message
include_file_revisionsThe output should include the explicit last-changed revision for each file.
templateTemplate for the output formatting, not used by all builders.
revision_idRevision id to print version for (optional)
def _extract_file_revisions(self):
Extract the working revisions for all files
def _iter_revision_history(self):
Find the messages for all revisions in history.
def _get_revision_id(self):
Get the revision id we are working on.
def _get_revno_str(self, revision_id):
Undocumented
def generate(self, to_file):
Output the version information to the supplied file.
Parametersto_fileThe file to write the stream to. The output will already be encoded, so to_file should not try to change encodings.
ReturnsNone
API Documentation for Bazaar, generated by pydoctor at 2022-06-16 00:25:16.