From d1f5b794ad0ce18cb4147af1c3cf1e5af0a8d0c2 Mon Sep 17 00:00:00 2001
From: Tom Wiesing <tkw01536@gmail.com>
Date: Fri, 6 Apr 2018 06:16:24 +0200
Subject: [PATCH] List projects and systems on people pages

---
 _includes/project_chip.html | 22 ++++++++++++++++++++++
 _includes/system_chip.html  | 22 ++++++++++++++++++++++
 _layouts/default.html       |  4 ++++
 _layouts/person.html        | 28 +++++++++++++++++++++++++++-
 projects/FormalCAD.md       |  1 +
 projects/almanac.md         |  1 +
 projects/arXMLiv.md         |  1 +
 projects/comma.md           |  1 +
 projects/jem.md             |  1 +
 projects/latin.md           |  1 +
 projects/logosphere.md      |  1 +
 projects/mamored.md         |  1 +
 projects/mathsearch.md      |  1 +
 projects/meta/README.md     |  3 +++
 projects/oaf.md             |  1 +
 projects/odk.md             |  1 +
 projects/omoc.md            |  1 +
 projects/once-cs.md         |  1 +
 projects/openmath-tn.md     |  1 +
 projects/sissi.md           |  1 +
 projects/tetrapod.md        |  1 +
 systems/TNTBase.md          |  1 +
 systems/cpoint.md           |  1 +
 systems/jobad.md            |  1 +
 systems/jomdoc.md           |  1 +
 systems/kat.md              |  1 +
 systems/krextor.md          |  1 +
 systems/llamapun.md         |  3 ++-
 systems/mathhub.md          |  1 +
 systems/meta/README.md      |  3 +++
 systems/mmt.md              |  1 +
 systems/mws.md              |  1 +
 systems/omdoc.md            |  1 +
 systems/openmathmap.md      |  1 +
 systems/sTeX.md             |  1 +
 systems/sally.md            |  1 +
 systems/smglom.md           |  1 +
 systems/swim.md             |  1 +
 38 files changed, 114 insertions(+), 2 deletions(-)
 create mode 100644 _includes/project_chip.html
 create mode 100644 _includes/system_chip.html

diff --git a/_includes/project_chip.html b/_includes/project_chip.html
new file mode 100644
index 0000000..b20b63e
--- /dev/null
+++ b/_includes/project_chip.html
@@ -0,0 +1,22 @@
+{% comment %}
+    This page creates a single 'chip' for linking to a project. 
+    It expects the name of the project as the 'project' variable
+{% endcomment %}
+
+{% capture purl %}/projects/{{include.project}}/{% endcapture %}
+{% assign pp = site.pages | where: "url", purl | first %}
+
+{% if pp %}
+    <a href="{{ site.baseurl }}{{purl}}">
+        <div class="chip">
+            {% if pp.logo %}
+                <img src="{{ site.baseurl }}/{{pp.logo}}"/>
+            {% endif %}
+            {{pp.shorttitle}}
+        </div>
+    </a>
+{% else %}
+    <div class="chip">
+        {{include.project}}
+    </div>
+{% endif %}
diff --git a/_includes/system_chip.html b/_includes/system_chip.html
new file mode 100644
index 0000000..c6cfa2a
--- /dev/null
+++ b/_includes/system_chip.html
@@ -0,0 +1,22 @@
+{% comment %}
+    This page creates a single 'chip' for linking to a system. 
+    It expects the name of the system as the 'system' variable
+{% endcomment %}
+
+{% capture surl %}/systems/{{include.system}}/{% endcapture %}
+{% assign sp = site.pages | where: "url", surl | first %}
+
+{% if sp %}
+    <a href="{{ site.baseurl }}{{surl}}">
+        <div class="chip">
+            {% if sp.logo %}
+                <img src="{{ site.baseurl }}/{{sp.logo}}"/>
+            {% endif %}
+            {{sp.shorttitle}}
+        </div>
+    </a>
+{% else %}
+    <div class="chip">
+        {{include.system}}
+    </div>
+{% endif %}
diff --git a/_layouts/default.html b/_layouts/default.html
index 00c1613..48835eb 100644
--- a/_layouts/default.html
+++ b/_layouts/default.html
@@ -1,3 +1,7 @@
+---
+layout: compress
+---
+
 {% assign sorted_pages = site.pages | sort: "menu_order" %}
 
 <!DOCTYPE html>
diff --git a/_layouts/person.html b/_layouts/person.html
index 6037979..f1c016d 100644
--- a/_layouts/person.html
+++ b/_layouts/person.html
@@ -2,6 +2,8 @@
 layout: default
 ---
 
+{% assign username = page.url | replace: '/people/', '' | replace: '/', '' %}
+
 <div class="row">
     
     <div class="col s12 m5 right">
@@ -36,6 +38,30 @@ layout: default
                     <hr />
                     {{ page.affiliation }}
                 {% endif %}
+
+                
+                <hr />
+                <!-- Projects -->
+                {% assign projects = site.pages | where: "layout", "project" | where: "active", true %}
+                {% for project in projects %}
+                    {% if project.people contains username %}
+                        {% assign pid = project.url | replace: '/projects/', '' | replace: '/', '' %}
+                        {% include project_chip.html project=pid %}
+                    {% endif %}
+                {% endfor %}
+
+                <hr />
+
+                <!-- Systems -->
+                {% assign systems = site.pages | where: "layout", "system" %}
+                {% for system in systems %}
+                    {% unless system.end_date %}
+                        {% if system.people contains username %}
+                            {% assign sid = system.url | replace: '/systems/', '' | replace: '/', '' %}
+                            {% include system_chip.html system=sid %}
+                        {% endif %}
+                    {% endunless %}
+                {% endfor %}
             </div>
             <div class="card-action">
                 {% if page.website %}
@@ -44,7 +70,7 @@ layout: default
                 {% endif %}
                 
                 {% if page.publink == "auto" %}
-                  <a href="http://kwarc.github.io/bibs/{{ page.url | replace: '/people/', '' | replace: '/', '' }}/">Publications</a>
+                  <a href="http://kwarc.github.io/bibs/{{ username }}/">Publications</a>
                 {% elsif page.publink %}
                   <a href="{{page.publink}}">Publications</a>
                 {% endif %}
diff --git a/projects/FormalCAD.md b/projects/FormalCAD.md
index dd23974..8048013 100644
--- a/projects/FormalCAD.md
+++ b/projects/FormalCAD.md
@@ -3,6 +3,7 @@ layout: project
 
 title: "FormalCAD: Formal Methods and Semantic Technologies for Engineering Design
 Processes"
+shorttitle: FormalCAD
 teaser: Towards a computer-supported, document-oriented process for systematic engineering design and a semantic help system for CAD systems.
 
 active: false
diff --git a/projects/almanac.md b/projects/almanac.md
index 43c52a5..eb03672 100644
--- a/projects/almanac.md
+++ b/projects/almanac.md
@@ -2,6 +2,7 @@
 layout: project
 
 title: "ALMANAC: Argumentation Logics Manager & Argument Context Graph"
+shorttitle: "ALMANAC"
 teaser: Decision situations require individuals and organizations to choose between a multitude of options based on facts, opinions, and arguments about the situation at hand or similar ones. There is already a large set of prior work on the representation of knowledge, inference, and argumentations; the ALMANAC aims to a) bring order into the zoo of proposed formalisms, b) categorize their inter-relations, and c) benchmark them on real-world corpora.
 
 active: true
diff --git a/projects/arXMLiv.md b/projects/arXMLiv.md
index e036d01..dd63756 100644
--- a/projects/arXMLiv.md
+++ b/projects/arXMLiv.md
@@ -2,6 +2,7 @@
 layout: project
 
 title: arXMLiv
+shorttitle: arXMLiv
 active: true
 teaser: Translating the arXiv to XML/HTML5 
 start_date: '2006'
diff --git a/projects/comma.md b/projects/comma.md
index 71e7ef2..26ce6f2 100644
--- a/projects/comma.md
+++ b/projects/comma.md
@@ -2,6 +2,7 @@
 layout: project
 
 title: "CoMMa: Corpus Meta-Mathematics"
+shorttitle: CoMMa
 active: true
 teaser: Representing and Extracting the Meaning of Mathematical/Technical Documents
 start_date: '2006'
diff --git a/projects/jem.md b/projects/jem.md
index f00b50e..8762a99 100644
--- a/projects/jem.md
+++ b/projects/jem.md
@@ -2,6 +2,7 @@
 layout: project
 
 title: "JEM: Joining Educational Mathematics"
+shorttitle: JEM
 teaser:  Coordination of European content enrichment activities in the area of mathematics
 
 active: false
diff --git a/projects/latin.md b/projects/latin.md
index bf74a7a..934f4f5 100644
--- a/projects/latin.md
+++ b/projects/latin.md
@@ -2,6 +2,7 @@
 layout: project
 
 title: "LATIN: Logic Atlas & Integrator"
+shorttitle: LATIN
 teaser: Building a theory graph of logic represesentations. 
 
 active: false
diff --git a/projects/logosphere.md b/projects/logosphere.md
index c0b556e..94dfa88 100644
--- a/projects/logosphere.md
+++ b/projects/logosphere.md
@@ -2,6 +2,7 @@
 layout: project
 
 title: "Logosphere: Formal Digital Libraries"
+shorttitle: Logosphere
 teaser: Integrating Theorem Prover Libraries through Meta-logical Frameworks
 
 active: false
diff --git a/projects/mamored.md b/projects/mamored.md
index 5fdcb91..4c2bcc4 100644
--- a/projects/mamored.md
+++ b/projects/mamored.md
@@ -2,6 +2,7 @@
 layout: project
 
 title: MaMoReD
+shorttitle: MaMoReD
 teaser: Flexiformalizing Mathematical Models as Research Data
 
 active: true
diff --git a/projects/mathsearch.md b/projects/mathsearch.md
index 6cb1600..5f2d56e 100644
--- a/projects/mathsearch.md
+++ b/projects/mathsearch.md
@@ -3,6 +3,7 @@ layout: project
 
 
 title: "MathSearch: Analyse und Suche in mathematischen Formeln"
+shorttitle: MathSearch
 teaser: Methods for information extraction and information retrieval for mathematical documents with the aim of providing semantically enhanced interaction for Zentralblatt Math and the arXiv.
 
 active: false
diff --git a/projects/meta/README.md b/projects/meta/README.md
index e8582f6..6a9523b 100644
--- a/projects/meta/README.md
+++ b/projects/meta/README.md
@@ -9,8 +9,11 @@ Each post needs some specific parameters:
  * **layout** use `project`
 
  * **title** the title of the project
+ * **shorttitle** the short title of the project, used for project chips
  * **teaser** (optional) a one-line description for the overview
 
+  * **logo** (optional) a (local) path to the logo of a project
+
  * **active** boolean indicating if the project is active
  * **start_date** the system start date (YYYY[-MM])
  * **end_date** (optional) the system end date (YYYY[-MM])
diff --git a/projects/oaf.md b/projects/oaf.md
index ccbee7d..e730507 100644
--- a/projects/oaf.md
+++ b/projects/oaf.md
@@ -2,6 +2,7 @@
 layout: project
 
 title: "OAF: An Open Archive for Formalizations"
+shorttitle: OAF
 teaser: The OAF Project builds a theoretical framework for interoperability of theorem prover libraries and implements an information system that host and align multiple libraries in a joint semantic setting.
 
 active: true
diff --git a/projects/odk.md b/projects/odk.md
index 05d6356..3b4bff5 100644
--- a/projects/odk.md
+++ b/projects/odk.md
@@ -2,6 +2,7 @@
 layout: project
 
 title: OpenDreamKit
+shorttitle: ODK
 teaser: Towards an Open Virtual Research Environment Framework for (Computational) Mathematics.
 
 active: true
diff --git a/projects/omoc.md b/projects/omoc.md
index 5b72d8a..163098f 100644
--- a/projects/omoc.md
+++ b/projects/omoc.md
@@ -2,6 +2,7 @@
 layout: project
 
 title: "OMoC: Ontology-based Management of Change"
+shorttitle: OMoC
 teaser: Using semantic features in document collections for better change management. 
 
 active: false
diff --git a/projects/once-cs.md b/projects/once-cs.md
index b35334d..4786ca9 100644
--- a/projects/once-cs.md
+++ b/projects/once-cs.md
@@ -2,6 +2,7 @@
 layout: project
 
 title: "ONCE-CS: Open Network of Centres of Excellence in Complex Systems"
+shorttitle: ONCE-CS
 teaser: Adding a Semantic Angle to Complex Systems
 
 active: false
diff --git a/projects/openmath-tn.md b/projects/openmath-tn.md
index d64a06f..cf65931 100644
--- a/projects/openmath-tn.md
+++ b/projects/openmath-tn.md
@@ -2,6 +2,7 @@
 layout: project
 
 title: Thematic Netork "OpenMath"
+shorttitle: TN "OpenMath"
 teaser: Integrating Math Software Systems by content Markup for Formulae
 
 active: false
diff --git a/projects/sissi.md b/projects/sissi.md
index bd0c82b..2241b80 100644
--- a/projects/sissi.md
+++ b/projects/sissi.md
@@ -2,6 +2,7 @@
 layout: project
 
 title: "SiSsI: Software Engineering for Spreadsheet Interaction"
+shorttitle: SiSsI
 teaser: Methods and technologies to enhance spreadsheets semantically.
 
 active: false
diff --git a/projects/tetrapod.md b/projects/tetrapod.md
index 2ad8b26..8a0045e 100644
--- a/projects/tetrapod.md
+++ b/projects/tetrapod.md
@@ -2,6 +2,7 @@
 layout: project
 
 title: Tetrapod
+shorttitle: Tetrapod
 teaser: All four dimensions of Mathematical Knowledge Processing
 
 active: true
diff --git a/systems/TNTBase.md b/systems/TNTBase.md
index b2051ae..0e04a05 100644
--- a/systems/TNTBase.md
+++ b/systems/TNTBase.md
@@ -2,6 +2,7 @@
 layout: system
 
 title: TNTBase
+shorttitle: TNTBase
 teaser: A  Versioned Storage for Mathematics (OMDoc) 
 
 start_date: 2009-09
diff --git a/systems/cpoint.md b/systems/cpoint.md
index 84416d5..e915ef8 100644
--- a/systems/cpoint.md
+++ b/systems/cpoint.md
@@ -2,6 +2,7 @@
 layout: system
 
 title: CPoint
+shorttitle: CPoint
 teaser: Adding a semantic layer to MS PowerPoint.
 
 start_date: 2001-07
diff --git a/systems/jobad.md b/systems/jobad.md
index aa7bc41..6254e70 100644
--- a/systems/jobad.md
+++ b/systems/jobad.md
@@ -2,6 +2,7 @@
 layout: system
 
 title: JOBAD
+shorttitle: JOBAD
 teaser: A Javascrip Framework for instrumenting Active Documents with Semantic Services
 start_date: 2008-09
 oprhan: true
diff --git a/systems/jomdoc.md b/systems/jomdoc.md
index 475da9a..0ba5afe 100644
--- a/systems/jomdoc.md
+++ b/systems/jomdoc.md
@@ -2,6 +2,7 @@
 layout: system
 
 title: JOMDoc
+shorttitle: JOMDoc
 teaser: A Java API for OMDoc documents
 
 start_date: 2007-09
diff --git a/systems/kat.md b/systems/kat.md
index 781ef16..275b6e3 100644
--- a/systems/kat.md
+++ b/systems/kat.md
@@ -2,6 +2,7 @@
 layout: system
 
 title: "KAT: KWARC Annotation Tool" 
+shorttitle: KAT
 teaser: An Annotation Tool for STEM Documents
 
 start_date: 2013-06
diff --git a/systems/krextor.md b/systems/krextor.md
index c4b1f34..b821630 100644
--- a/systems/krextor.md
+++ b/systems/krextor.md
@@ -2,6 +2,7 @@
 layout: system
 
 title: Krextor
+shorttitle: Krextor
 teaser: An extensible XSLT-based framework for extracting RDF from XML.
 
 start_date: 2008-02
diff --git a/systems/llamapun.md b/systems/llamapun.md
index 22ee76e..5ae64ab 100644
--- a/systems/llamapun.md
+++ b/systems/llamapun.md
@@ -1,7 +1,8 @@
 ---
 layout: system
 
-title: "LLaMaPuN: Language and Mathematics Processing and Understanding" 
+title: "LLaMaPuN: Language and Mathematics Processing and Understanding"
+shorttitle: LLaMaPuN
 teaser: A RUST library for math corpus linguistics.
 
 start_date: 2008-11
diff --git a/systems/mathhub.md b/systems/mathhub.md
index 0839b1b..85c1770 100644
--- a/systems/mathhub.md
+++ b/systems/mathhub.md
@@ -2,6 +2,7 @@
 layout: system
 
 title: MathHub.info
+shorttitle: MathHub
 teaser: A portal for active mathematical documents and an archive for flexiformal mathematics.
 
 start_date: 2008-08
diff --git a/systems/meta/README.md b/systems/meta/README.md
index d246b60..0c4a938 100644
--- a/systems/meta/README.md
+++ b/systems/meta/README.md
@@ -9,8 +9,11 @@ Each post needs some specific parameters:
  * **layout** use `system`
  
  * **title** the title of the system
+ * **shorttitle** the short title of the system, used for System Chips
  * **teaser** (optional) a one-line description for the overview
 
+ * **logo** (optional) a (local) path to the logo of a system
+
  * **start_date** the system start date (YYYY[-MM])
  * **end_date** (optional) the system end date (YYYY[-MM])
 
diff --git a/systems/mmt.md b/systems/mmt.md
index 19763ff..865f8ac 100644
--- a/systems/mmt.md
+++ b/systems/mmt.md
@@ -2,6 +2,7 @@
 layout: system
 
 title: "MMT"
+shorttitle: MMT
 teaser: A framework for representing declarative languages such as logics, type theories, set theories, etc.. The MMT API implements complex algorithms generically for any language in the framework.
 
 start_date: 2011-03
diff --git a/systems/mws.md b/systems/mws.md
index c9fc688..f41016f 100644
--- a/systems/mws.md
+++ b/systems/mws.md
@@ -2,6 +2,7 @@
 layout: system
 
 menu_title: MathWebSearch
+shorttitle: MWS
 title: MathWebSearch
 teaser: A Mathematical Search Engine
 
diff --git a/systems/omdoc.md b/systems/omdoc.md
index 7e162d8..29dfc8d 100644
--- a/systems/omdoc.md
+++ b/systems/omdoc.md
@@ -2,6 +2,7 @@
 layout: system
 
 title: "OMDoc: Open Mathematical Documents"
+shorttitle: OMDoc
 teaser: A markup format and data model for Open Mathematical Documents. It serves as semantics-oriented representation format and ontology language for mathematical knowledge.
 
 start_date: '1998'
diff --git a/systems/openmathmap.md b/systems/openmathmap.md
index 0458ce5..6ec412c 100644
--- a/systems/openmathmap.md
+++ b/systems/openmathmap.md
@@ -2,6 +2,7 @@
 layout: system
 
 title: OpenMathMap
+shorttitle: OpenMathMap
 teaser: A Map of Mathematics
 
 start_date: 2013-06 
diff --git a/systems/sTeX.md b/systems/sTeX.md
index d0eea56..01ed543 100644
--- a/systems/sTeX.md
+++ b/systems/sTeX.md
@@ -2,6 +2,7 @@
 layout: system
 
 title: "sTeX: Semantic Markup for LaTeX"
+shorttitle: sTeX
 
 start_date: 2004-09
 
diff --git a/systems/sally.md b/systems/sally.md
index 908fa41..9acdfc1 100644
--- a/systems/sally.md
+++ b/systems/sally.md
@@ -2,6 +2,7 @@
 layout: system
 
 title: Semantic Alliance
+shorttitle: Sally
 teaser: A framework for mashing up semantic services into desktop applications.
 
 start_date: 2013-02
diff --git a/systems/smglom.md b/systems/smglom.md
index c3a8e4b..211f484 100644
--- a/systems/smglom.md
+++ b/systems/smglom.md
@@ -2,6 +2,7 @@
 layout: system
 
 title: "SMGLoM - A Semantic, Multilingual Glossary of Mathematics"
+shorttitle: SMGLoM
 teaser: A terminological resource for Mathematics. 
 
 start_date: 2013-11
diff --git a/systems/swim.md b/systems/swim.md
index 0768c1f..e0b1977 100644
--- a/systems/swim.md
+++ b/systems/swim.md
@@ -2,6 +2,7 @@
 layout: system
 
 title: "SWiM: Semantic Wiki for Mathematics"
+shorttitle: SWiM
 teaser: A Semantic Wiki for Interactive Mathematics.
 
 start_date: 2006-08
-- 
GitLab