{% for p in publications %}
{{ p.title }}
{% for a in p.authors -%}
{%- if a.internal -%}
{%- assign person = site.data.people.people[a.internal]-%}
{{ person.name }}
{%- else if -%}
{{ a.external }}
{%- endif -%}
{%- unless forloop.last -%}, {% endunless-%}
{%- endfor %}
{%- assign prefix = site.data.publications.types[p.type].prefix -%}
{{ prefix }}{{ p.venue }}
{%- if p.series %} ({{ p.series }}){%- endif -%},
{% if p.location %}{{ p.location }},{% endif %} {{ p.year }}.
{%- if p.awards -%}
{% for a in p.awards -%}
{{ a }}
{%- unless forloop.last -%}, {% endunless-%}
{%- endfor %}
{%- endif -%}
{%- if p.resources -%}
{% for r in p.resources %}
{%- if r.internal -%}
{%- capture link -%}
{{ "/assets/publications/" | relative_url}}{{ r.internal }}
{%- endcapture -%}
{%- else -%}
{%- assign link = r.external -%}
{%- endif -%}
{%- assign label = site.data.publications.restypes[r.type].label -%}
[{{ label }}]
{% endfor %}
{%- endif -%}
{% endfor %}