{# ---MACROS AND CODE START #}
{% macro print_commit(change) %}{# MACRO needs to be all on one line #}
{% if change.scope %}- **{{ change.scope }}**: {{ change.message }} - *{{ change.author }} ({{ change.sha1[:7] }})*{% else %}{% if change.message %}- {{ change.message }} - *{{ change.author }} ({{ change.sha1[:7] }})*{% endif %}{% endif %}
{% endmacro %}{# MACRO needs to be all on one line #}
{#    MACROS AND CODE END--- #}

{# ---HEADER START #}
# Changelog

All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
{#    HEADER END--- #}

---

{# ---BODY START #}
{% for entry in tree %}{# ---BLOCK release version #}
{% if not (entry.version == 'Unreleased' and not config.include_unreleased) %}
## {{ entry.version }}{% if entry.date %} ({{ entry.date }}){% endif %}
{% for change_key, changes in entry.changes.items() %}{# ---BLOCK sections #}

{% if change_key %}{# ---BLOCK section header #}
### {{ change_key }}
{% endif %}{# BLOCK section header--- #}
{% for change in changes %}{# ---BLOCK commit record #}
{{ print_commit(change) }}
{% endfor %}{# BLOCK commit record--- #}
{% endfor %}{# BLOCK sections--- #}

{# keep empty line above this comment #}
---

{% endif %}
{# keep empty line above this comment #}
{% endfor %}{# BLOCK release vesion--- #}
{#    BODY END--- #}
{# ---FOOTER START #}
**Created by [Espressif Systems CO LTD.](https://www.espressif.com/)**
- [Commitizen tools plugin with Espressif code style](https://www.github.com/espressif/cz-plugin-espressif)
- [Espressif Coding Standards and Best Practices](https://www.github.com/espressif/standards)
{#    FOOTER END--- #}
