Skip to content

Commit

Permalink
🐛 fix errant rendering of parsed_commit_heading stub
Browse files Browse the repository at this point in the history
Signed-off-by: rjdbcm <[email protected]>
  • Loading branch information
rjdbcm committed Jun 21, 2024
1 parent 5428424 commit 96c0306
Show file tree
Hide file tree
Showing 5 changed files with 4 additions and 6 deletions.
2 changes: 1 addition & 1 deletion ozi/render.py
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ def render_templates(env: Environment, target: Path) -> None:
:param target: directory path to render the project
:type target: Path
"""
for i in ['.release_notes.md.j2', 'CHANGELOG.md.j2', 'parsed_commit_heading.j2']:
for i in ['.release_notes.md.j2', 'CHANGELOG.md.j2', '.parsed_commit_heading.j2']:
template = env.get_template(f'templates/{i}')
f = target / 'templates' / i
f.parent.mkdir(exist_ok=True, parents=True)
Expand Down
2 changes: 0 additions & 2 deletions parsed_commit_heading

This file was deleted.

File renamed without changes.
2 changes: 1 addition & 1 deletion templates/.release_notes.md.j2
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
## What's Changed
{% for type_, commits in release["elements"] | dictsort %}
{% include 'parsed_commit_heading.j2' %}
{% include '.parsed_commit_heading.j2' %}
{%- if type_ != "unknown" %}
{% for commit in commits %}
* {{ commit.descriptions[0]|replace(type_~': ','')|replace(type_,'')|replace('---', '') }} &mdash; by {{commit.commit.author.name}} in [`{{ commit.short_hash }}`]({{ commit.hexsha | commit_hash_url }})
Expand Down
4 changes: 2 additions & 2 deletions templates/CHANGELOG.md.j2
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
## Unreleased
{% for type_, commits in context.history.unreleased | dictsort %}
{% for commit in commits %}{% if type_ != "unknown" %}
{% include 'parsed_commit_heading.j2' %}
{% include '.parsed_commit_heading.j2' %}
* {{ commit.commit.message.rstrip()|replace(type_~': ','')|replace(type_,'')|replace('---', '')|replace('\n\nSigned-off-by:', ' —') }} ([`{{ commit.commit.hexsha[:7] }}`]({{ commit.commit.hexsha | commit_hash_url }}))
{% else %}
* {{ commit.commit.message.rstrip()|replace(type_~': ','')|replace(type_,'')|replace('---', '')|replace('\n\nSigned-off-by:', ' —') }} ([`{{ commit.commit.hexsha[:7] }}`]({{ commit.commit.hexsha | commit_hash_url }}))
Expand All @@ -17,7 +17,7 @@
{% for version, release in context.history.released.items() %}
## {{ version.as_tag() }} ({{ release.tagged_date.strftime("%Y-%m-%d") }})
{% for type_, commits in release["elements"] | dictsort %}
{% include 'parsed_commit_heading.j2' %}
{% include '.parsed_commit_heading.j2' %}
{% for commit in commits %}{% if type_ != "unknown" %}
* {{ commit.commit.message.rstrip()|replace(type_~': ','')|replace(type_,'')|replace('---', '')|replace('\n\nSigned-off-by:', ' —') }} ([`{{ commit.commit.hexsha[:7] }}`]({{ commit.commit.hexsha | commit_hash_url }}))
{% else %}
Expand Down

0 comments on commit 96c0306

Please sign in to comment.