Closed gschare closed 2 years ago
M&K has taught the Lab Seminar, GU8906: Craft and Science: Making Objects in the Early Modern World since 2014 with each semester organized around a different theme. Students undertake hands-on work in the laboratory while keeping hybrid lab/field notes, resulting in the pages archived here. They include notes for skill-building exercises as well as their original research towards an annotation (what then became the Research Essays of Secrets of Craft and Nature)
Actions:
Example of deepest directory:
<html>
<head>
<title>Fieldnotes Spring 2022 | Gregory Schare</title>
</head>
<body>
<p><a href="/home.html"><- home</a>
<br/>
<a href="/sp22/fld/index.html"><- back to Spring 2022 Fieldnotes</a></p>
<p/>
<p>
<h2>
<ul>
<li><a href="https://google.com">Making Varnish</a></li>
<li><a href="https://google.com">Excellent Mustard</a></li>
<li><a href="https://google.com">I was on the MKP Digital Team. This is my story.</a></li>
</ul>
</h2>
</p>
</body>
</html>
We need content (descriptions of what these are) for the following types pages:
e.g., the home page would be whatever landing page, contextual BLAH we want to say e.g., semester would have descriptions about the theme and what the course did
@gschare please provide structure for this content for me to fill in
I am going off of what I did for Columbia Space Initiative, which uses Jekyll, and for the issue tracker archive, which uses pandoc templating.
A template for a type of page (e.g. semester, field notes) will look rather like this: https://github.com/columbiaspace/columbiaspace.org/blob/master/_includes/mission.html
There is also the content which will be written mostly by Naomi and substituted into the template to form a complete, statically-generated HTML file. That is technically an HTML file but it will mostly consist of YAML headers specifying what the variables will be substituted with. Here is an example of that which gets inserted into the above template: https://github.com/columbiaspace/columbiaspace.org/blob/master/missions/mission-spocs.html
A template is a single HTML file kept in a special folder in the repo which describes how a class of files should be formatted. It includes variables which, during generation, are filled in with values. Here, the variables are enclosed in $
.
For example, the template for a student's index of fieldnotes in a given semester looks something like this:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" type="text/css" href="">
<title>$student$ Fieldnotes | $fullsemester$</title>
</head>
<body>
<h1>$student$ Fieldnotes | $fullsemester$</h1>
<p>$intro$</p>
<br>
<ul>
$for(pages)$
<li><b><a href="$it.link$">$it.title$.</a></b> $it.desc$</li>
$endfor$
</ul>
</body>
</html>
Technically a Markdown file, but the most important thing is the YAML header at the top which details the content for each variable in the template.
There is a one-to-one correspondence between these files and the files that get generated at the end. So, we will need one of these "content files" for each of the files we want to generate.
For example, Nina Elizondo-Garza's content might look something like this:
---
title: "Nina Elizondo-Garza Fieldnotes"
template: fieldnote
semester: "fa17"
fullsemester: "Fall 2017"
student: "Nina Elizondo-Garza"
intro: "Nina is a person. She was born at a very young age."
pages:
- title: "Historical Culinary Reconstruction"
link: "fa17_fld_elizondo-garza_nina_hcr.html"
desc: ""
- title: "Verdigris Experiment"
link: "fa17_fld_elizondo-garza_nina_verdigris-experiment.html"
desc: ""
- title: "An Exploration of Bread Making"
link: "fa17_fld_elizondo-garza_nina_an-exploration-of-bread-making.html"
desc: ""
- title: "From Madder Root to Madder Lake"
link: "fa17_fld_elizondo-garza_nina_from-madder-root-to-madder-lake.html"
desc: ""
- title: "Azurite"
link: "fa17_fld_elizondo-garza_nina_azurite.html"
desc: ""
- title: "Flour Stucco and Paste Glue"
link: "../dongchung_tenzin/fa17_fld_dongchung_tenzin_stucco.html"
desc: ""
- title: "Annotation Plans"
link: "../../ann/stucco_elizono-garza/fa17_ann_stucco_elizondo-garza_annotation-plans.html"
desc: ""
- title: "Stucco Annotation Fieldnotes"
link: "../../ann/stucco_elizono-garza/fa17_ann_stucco_elizondo-garza-stucco-fol-29r-1.html"
desc: ""
- title: "Stucco Annotation - Painting Stucco"
link: "../../ann/stucco_elizono-garza/fa17_ann_stucco_elizondo-garza_stucco-annotation-painting-stucco.html"
desc: ""
---
To generate the file corresponding to the index.md
for Nina above, use this:
pandoc -s -o index.html --template fieldnote.html index.md
This will generate a file called index.html
which looks just like fieldnote.html
, but the variables will be filled in with the content from index.md
.
I am still figuring this out. Should be trivial to add it to the template and/or incantation.
thanks arthur
index.md
) for every folder in the repoTemplates and all index.md files have been created, as of 8225f739.
It remains to add content for index.md files and adjust templates until we like how it looks.
This is now continued in #25
We need a template for what the new navigable index pages should be.
I think we can keep this quite simply, and essentially just have:
Let me know if anything else should be added.