janispagel.de

Source code for https://janispagel.de
Log | Files | Refs | README | LICENSE

commit ad260c62ed7b37dad84efcbf66a08e794e98a928
parent 8315b63cbc718cdcf9945d93b87d87ba3531e42f
Author: Janis Pagel <janis.pagel@ims.uni-stuttgart.de>
Date:   Fri, 19 Jun 2020 06:54:19 +0200

Unify publication appearance

Diffstat:
D_includes/pub/filtered-collection.html | 45---------------------------------------------
A_includes/pub/filtered.html | 62++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Mpublications/all.html | 65++---------------------------------------------------------------
Mpublications/article.html | 2+-
Mpublications/incollection.html | 2+-
Mpublications/inproceedings.html | 2+-
Mpublications/thesis.html | 6+++---
7 files changed, 70 insertions(+), 114 deletions(-)

diff --git a/_includes/pub/filtered-collection.html b/_includes/pub/filtered-collection.html @@ -1,45 +0,0 @@ -{% assign pubs = include.publications | where: "toappear", true %} - -{% if pubs.size > 0 %} - -<h2 style="margin-top:20px;">to appear</h2> -{% for pub in pubs %} -<div class="publication" lang="{{pub.lang}}">{% include pub/{{ pub.type }}.html p=pub %} -</div> -{% endfor %} - -{% endif %} - -{% assign years = include.publications | map: "year" | uniq | sort | reverse %} - -{% for y in years %} - -{% assign thisyear = include.publications | where:"year", y | where_exp: "item", "item.toappear != true" %} - -{% if thisyear.size == 0 %} -{% continue %} -{% endif %} - -{% if include.showYear %}<h2>{{ y }}</h2>{% endif %} -{% assign thisyear = thisyear | sort: 'month', 'first' | reverse %} -{% for pub in thisyear %} - -{% if pub.toappear %} -{% continue %} -{% endif %} -<div class="publication" lang="{{pub.lang}}">{% include pub/{{ pub.type }}.html p=pub %} - <p class="right_aligned"> - {% if pub.doi %} - <a href="http://dx.doi.org/{{pub.doi}}">[doi]</a> - {% endif %} - {% if pub.downloads %} - {% for d in pub.downloads %} - <a href="{{d.url}}">[{{d.desc}}]</a> - {% endfor %} - {% endif %} - <a href="{{pub.url}}">[cite]</a> - </p> -</div> -{% endfor %} - -{% endfor %} diff --git a/_includes/pub/filtered.html b/_includes/pub/filtered.html @@ -0,0 +1,62 @@ +{% assign pubs = include.publications | where: "toappear", true %} + +{% if pubs.size > 0 %} +<h2 style="margin-top:20px;">to appear</h2> +<ul> +{% for pub in pubs %} +<div class="publication" lang="{{pub.lang}}"><li>{% include pub/{{ pub.type }}.html p=pub %} + <p class="right_aligned"> + {% if pub.doi %} + <a href="http://dx.doi.org/{{pub.doi}}">[doi]</a> + {% endif %} + {% if pub.iurl %} + <a href="{{pub.iurl}}">[paper]</a> + {% endif %} + {% if pub.downloads %} + {% for d in pub.downloads %} + <a href="{{d.url}}">[{{d.desc}}]</a> + {% endfor %} + {% endif %} + <a href="{{pub.url}}">[cite]</a> + </p> +</li></div> +{% endfor %} +</ul> +{% endif %} + +{% assign years = include.publications | map: "year" | uniq | sort | reverse %} + +{% for y in years %} + +{% assign thisyear = include.publications | where:"year", y | where_exp: "item", "item.toappear != true" %} + +{% if thisyear.size == 0 %} +{% continue %} +{% endif %} + +{% assign thisyear = thisyear | sort: 'month', 'first' | reverse %} + +<h2>{{ y }}</h2> +<ul> + +{% for pub in thisyear %} + +<div class="publication" lang="{{pub.lang}}"><li>{% include pub/{{ pub.type }}.html p=pub %} + <p class="right_aligned"> + {% if pub.doi %} + <a href="http://dx.doi.org/{{pub.doi}}">[doi]</a> + {% endif %} + {% if pub.iurl %} + <a href="{{pub.iurl}}">[paper]</a> + {% endif %} + {% if pub.downloads %} + {% for d in pub.downloads %} + <a href="{{d.url}}">[{{d.desc}}]</a> + {% endfor %} + {% endif %} + <a href="{{pub.url}}">[cite]</a> + </p> +</li</div> +{% endfor %} +</ul> +{% endfor %} diff --git a/publications/all.html b/publications/all.html @@ -6,67 +6,6 @@ keywords: menu: "pub/menu.html" --- -{% assign pubs = site.publications | where: "toappear", true %} +{% assign filtered_publications = site.publications %} -{% if pubs.size > 0 %} -<h2 style="margin-top:20px;">to appear</h2> -<ul> -{% for pub in pubs %} -<div class="publication" lang="{{pub.lang}}"><li>{% include pub/{{ pub.type }}.html p=pub %} - <p class="right_aligned"> - {% if pub.doi %} - <a href="http://dx.doi.org/{{pub.doi}}">[doi]</a> - {% endif %} - {% if pub.iurl %} - <a href="{{pub.iurl}}">[paper]</a> - {% endif %} - {% if pub.downloads %} - {% for d in pub.downloads %} - <a href="{{d.url}}">[{{d.desc}}]</a> - {% endfor %} - {% endif %} - <a href="{{pub.url}}">[cite]</a> - </p> -</li></div> -{% endfor %} -</ul> -{% endif %} - -{% assign years = site.publications | map: "year" | uniq | sort | reverse %} -{% for y in years %} - - - -{% assign thisyear = site.publications | where:"year", y | where_exp: "item", "item.toappear != true" %} - -{% if thisyear.size == 0 %} -{% continue %} -{% endif %} - - -{% assign thisyear = thisyear | sort: 'month', 'first' | reverse %} - -<h2>{{ y }}</h2> -<ul> - -{% for pub in thisyear %} - -<div class="publication" lang="{{pub.lang}}"><li>{% include pub/{{ pub.type }}.html p=pub %} - <p class="right_aligned"> - {% if pub.doi %} - <a href="http://dx.doi.org/{{pub.doi}}">[doi]</a> - {% endif %} - {% if pub.iurl %} - <a href="{{pub.iurl}}">[paper]</a> - {% endif %} - {% if pub.downloads %} - {% for d in pub.downloads %} - <a href="{{d.url}}">[{{d.desc}}]</a> - {% endfor %} - {% endif %} - <a href="{{pub.url}}">[cite]</a> - </p> -</li></div> -{% endfor %} -</ul> -{% endfor %} +{% include pub/filtered.html publications=filtered_publications %} diff --git a/publications/article.html b/publications/article.html @@ -8,4 +8,4 @@ menu: "pub/menu.html" {% assign filtered_publications = site.publications | where:"type", "article" %} -{% include pub/filtered-collection.html publications=filtered_publications showYear=true %} +{% include pub/filtered.html publications=filtered_publications %} diff --git a/publications/incollection.html b/publications/incollection.html @@ -8,4 +8,4 @@ menu: "pub/menu.html" {% assign filtered_publications = site.publications | where:"type", "incollection" %} -{% include pub/filtered-collection.html publications=filtered_publications showYear=true %} +{% include pub/filtered.html publications=filtered_publications %} diff --git a/publications/inproceedings.html b/publications/inproceedings.html @@ -8,4 +8,4 @@ menu: "pub/menu.html" {% assign filtered_publications = site.publications | where:"type", "inproceedings" %} -{% include pub/filtered-collection.html publications=filtered_publications showYear=true %} +{% include pub/filtered.html publications=filtered_publications %} diff --git a/publications/thesis.html b/publications/thesis.html @@ -10,6 +10,6 @@ menu: "pub/menu.html" {% assign filtered_publications_master = site.publications | where:"type", "mastersthesis" %} {% assign filtered_publications_bachelor = site.publications | where:"type", "bachelorsthesis" %} -{% include pub/filtered-collection.html publications=filtered_publications_phd showYear=true %} -{% include pub/filtered-collection.html publications=filtered_publications_master showYear=true %} -{% include pub/filtered-collection.html publications=filtered_publications_bachelor showYear=true %} +{% include pub/filtered.html publications=filtered_publications_phd %} +{% include pub/filtered.html publications=filtered_publications_master %} +{% include pub/filtered.html publications=filtered_publications_bachelor %}