templating
Templating functions.
CLASS | DESCRIPTION |
---|---|
RenderedChangelog |
The output of rendering a changelog. |
FUNCTION | DESCRIPTION |
---|---|
get_default_env |
The default Jinja environment for rendering a changelog. |
get_pipeline_env |
The Jinja environment for rendering actions and pipelines. |
render_changelog |
Render the full or incremental changelog for the repository to a string. |
Classes¶
RenderedChangelog
dataclass
¶
RenderedChangelog(
heading: Optional[str] = None,
notes: Optional[str] = None,
full: Optional[str] = None,
)
The output of rendering a changelog.
If it is an incremental changelog, full
contains {heading}\n{notes}
If it is a full changelog, heading
and notes
are empty.
Functions¶
get_default_env
¶
get_default_env(config: Optional[Configuration] = None) -> Environment
The default Jinja environment for rendering a changelog.
get_pipeline_env
¶
get_pipeline_env(config: Optional[Configuration] = None) -> Environment
The Jinja environment for rendering actions and pipelines.
render_changelog
¶
render_changelog(
version_context: List[VersionContext],
config: Configuration,
incremental: bool = False,
) -> RenderedChangelog
Render the full or incremental changelog for the repository to a string.
PARAMETER | DESCRIPTION |
---|---|
version_context
|
The processed commits
TYPE:
|
config
|
The current configuration object.
TYPE:
|
incremental
|
TYPE:
|
RETURNS | DESCRIPTION |
---|---|
RenderedChangelog
|
The full or partial changelog |