Skip to content

Commit 74951fd

Browse files
committed
Attempt to add book authors
1 parent 32eea4e commit 74951fd

1 file changed

Lines changed: 11 additions & 1 deletion

File tree

_layouts/bib.liquid

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,17 @@
151151
{% if entry.type == 'article' %}
152152
{% capture entrytype %}<em>{{ entry.journal }}</em>{% endcapture %}
153153
{% elsif proceedings contains entry.type %}
154-
{% capture entrytype %}<em>In {{ entry.booktitle }}</em>{% endcapture %}
154+
{% assign entrytype = 'In ' %}
155+
{% if entry.bookauthor %}
156+
{%- for author in entry.bookauthor_array -%}
157+
{% capture entrytype %}{{ entrytype }}{{- author.first }}{{ " " }}{{ author.last -}}{% endcapture %}
158+
{%- if forloop.length > 1 -%}
159+
{% if forloop.first == false %}{% assign entrytype | append ",&nbsp;" %}{% endif %}
160+
{%- if forloop.last %}{% assign entrytype | append "&&nbsp;" %}{% endif -%}
161+
{% endif %}
162+
{% endfor %}
163+
{% endif %}
164+
{% assign entrytype | append {{ entry.booktitle }} | append "</em>" %}
155165
{% elsif thesis contains entry.type %}
156166
{% capture entrytype %}<em>{{ entry.school }}</em>{% endcapture %}
157167
{% else %}

0 commit comments

Comments
 (0)