{% set colors = {'DEF': '\033[0m', 'TITLE': '\033[95m', 'UNSPECIFIED': '\033[0m', 'LOW': '\033[94m', 'MEDIUM': '\033[93m', 'HIGH': '\033[91m'} %}

{{ colors.TITLE }}==================== Results ==================={{ colors.DEF }}
{% for path, issues in reports.items() %}
{% if reports|length > 1 %}
File path: {{ path }}
{% endif %}
{% if not issues %}
No issues found.

{% else %}

{% for issue in issues|sort(attribute='severity') %}
{{ colors[issue.severity] }}>> Problem: [{{ issue.plugin }}] {{ issue.summary }}{{ colors.DEF }}
{% if issue.description %}
Description: {{ issue.description }}
{% endif %}
{% if issue.help_url %}
Additional info: {{ issue.help_url }}
{% endif %}
{% if issue.reason %}
Reason: {{ issue.reason }}
{% endif %}
Pseudo config:
{{ issue.config | to_text }}

{% if not loop.last %}
------------------------------------------------

{% endif %}
{% endfor %}
{% endif %}
{% if not loop.last %}
--------8<--------8<--------8<--------8<--------
{% endif %}
{% endfor %}
{% if stats %}
{{ colors.TITLE }}==================== Summary ==================={{ colors.DEF }}
Total issues:
    Unspecified: {{ stats.UNSPECIFIED }}
    Low: {{ stats.LOW }}
    Medium: {{ stats.MEDIUM }}
    High: {{ stats.HIGH }}
{% endif %}
