Add explicit start/end to pegleg site render output

When performing pegleg <options> site <site_name> render -o <output>
the resulting output doesn't include a "start_end" or "start_end"
(meaning '---' at the beginning and '...' at the end). This corrects
that issue.

Change-Id: Ife8c3a74413957b9ac4be187047ce5543a399b8e
This commit is contained in:
Felipe Monteiro 2018-09-24 21:37:37 +01:00
parent deddf0df1d
commit 58baf06d06
1 changed files with 6 additions and 1 deletions

View File

@ -104,7 +104,12 @@ def render(site_name, output_stream):
else:
err_msg += str(err) + '\n'
raise click.ClickException(err_msg)
yaml.dump_all(rendered_documents, output_stream, default_flow_style=False)
yaml.dump_all(
rendered_documents,
output_stream,
default_flow_style=False,
explicit_start=True,
explicit_end=True)
def list_(output_stream):