{# both macro pairs must have the same signature #} {% macro id_replace(rev, url) -%} {%- if rev|length > 40 %}{{ rev[:40] }}... {%- else %}{{ rev }} {%- endif -%} {%- endmacro %} {% macro shorten_replace(short, rev, url) %}
{% endmacro %} {% macro id(rev, url) -%} {%- if rev|length > 40 %}{{ rev[:40] }}... {%- else %}{{ rev }} {%- endif -%} {%- endmacro %} {% macro shorten(short, rev, url) %}