-
Notifications
You must be signed in to change notification settings - Fork 12
Adding items to the library
This guide will help walk you through how to add a new item to the library.
The first thing you'll have to decide is what kind of item is it?
The library has nine content categories, which are the subfolders of the main _content folder:
- articles
- av
- booklets
- canon
- essays
- excerpts
- monographs
- papers
- reference
These break down as follows:
- Audio/Visual material goes into "av".
- Canonical works (e.g. suttas) go into "canon".
- Self-published books are "booklets"
- Books with professional publishers are "monographs"
- Self-published writings shorter than a book are called "essays"
- unless they were published as part of a book, in which case it's an "excerpt".
- If a research paper was published in a journal or periodical, that's an "article"
- If it was published in an edited volume, that's a "paper".
- "Reference" is basically anything else.
Simple! 🙈
Once you've decided which subfolder your new item belongs in, your new entry will need a name. The filename is important as Jekyll will use the name to generate the URL for the item.
Library item filenames should be in the form: work-title_author.md Where:
- The work-title slug should usually not start with
a-orthe- - The author's names should come after an underscore, in last-first format
- Works with two authors should just list their last names
last1-last2 -
-et-alcan be added to the end for works with many authors - authors with entries in the
_authorsfolder should use that slug instead of their full name (e.g. justsome-title_appleton.mdinstead ofsome-title_appleton-naomi.md) - The entire filename must not contain spaces, apostrophes, quotes, uppercase letters or unicode characters.
Whenever I make a new entry, I first paste this template as the body of the new file:
---
title: ""
authors:
-
subcat:
editor:
translator:
external_url: ""
source_url: ""
drive_links:
- ""
file_links:
- ""
formats: []
status: featured
course:
tags:
-
year:
month:
olid:
oclc:
journal:
publisher:
address: ""
volume:
series:
number:
from_book:
booktitle: ""
pages: "--"
chapter:
minutes:
---
>
Don't worry! You won't need to fill in most of these. Having a template just means that you won't accidentally forget or mistype a field.
Let's go through this template one line at a time to understand it.
The first line contains exactly three hyphens.
This tells Jekyll that what follows is Yaml-formatted frontmatter data.
See this guide for more information about Yaml syntax.
The title of the work. This field is required for all items in the library.
If a word in the title needs to be italicized, add an asterisk before and after it:
title: "The Meaning of *sati*: Memory or Mindfulness?"This is a yaml list of author objects.
An author object is either:
- A quoted string containing the full name of the author (e.g.
"Mark Twain") - The slug of an
_author/(e.g.bodhifor Bhikkhu Bodhi)
If there are more than five authors, you can add and others to the end of the fourth author, for example:
authors:
- bodhi
- sujato
- "Someone Else"
- "Another Author and others"If the work is a sutta, for example, you may erase this field and fill in translator: instead (see below).
This field can be one of the following values: thesis, poetry, podcast, music, film, course, or fiction.
If none of those is applicable, this field may be erased.
These fields each take one author object as above.
If there are multiple editors, put them into one long string separated by " and ". For example, editor: "Bugs Bunny and Daffy Duck and Porky Pig"
This is the main link to the item.
The link must be to the actual item itself and not to e.g. a review. Canonical (i.e. from the original publisher) links are preferred if possible.
Note that links to Google Drive don't go here. They have a dedicated field below.
The canonical url may be undesirable if it's a redirect url (such as a DOI), a confusing webpage, a poor quality PDF, grouped together with other content, served only over http, etc.
In such cases, the canonical url (or similar) may be put here in "source_url" and a better url should be placed in external_url if one is available.
These URLs will be checked monthly to ensure that they are still live and will be updated as needed.
This field is a list of Google Drive links to the item in question.
Usually there will only be one link (to a PDF), but the list allows for multiple links if the work is available in multiple formats (see below).
If the file is hosted directly by OBU, its file handles will appear here.
This array tells the formats of the Drive and file links above.
By default, this is formats: [mp3] for av works and formats: [pdf, epub] for everything else.
Erase this template line if you're okay with the defaults.
Works of especially high quality will be status: featured.
For most works, simply erase this line.
For more information about how this works, see the collection policy document.
The course field gets the slug of the _tag or _course that this piece of content belongs to, and the tags list is for all the topics this item is related to.
When the work was first published, approximately.
The year (e.g. year: 2013) is required for all items.
If it's unknown, make an educated guess and add a comment explaining what you know, for example:
year: 1999 # sometime 1995–2003Month is the first three letters of the month name in lower case, e.g. month: sep if known.
This is an OpenLibrary ID.
We use the OpenLibrary API for monograph covers. If you're adding a new monograph and want it to have a pretty picture of the cover, find (or add) the book on OpenLibrary and upload a snazzy cover image for it there. Then simply copy and paste the OLID to this field and the cover will appear on the site. 🪄
This is the WorldCat identifier, added for copyrighted monographs.
The periodical that an article was published in.
This field is used IFF the item is an article.
Journal can be a slug (journal: jjrs) or a string (journal: "Good Housekeeping").
See _journals for the list of available journal slugs.
The company or organization which published a work.
Required for monographs, it must be absent from booklets and is optional for other categories.
Publisher can be a slug (bps) or a string ("Acme Corp").
See _publishers for the list of slugs.
If a string publisher is specified, you should also provide an "address" which is simply the city or country where a work was published, e.g. address: "New York"
If you know the volume number for the journal issue, supply it here.
This is a slug to a _series object, used to tie N, numbered items together.
First, create a _series/ file for the series as a whole, then add all the items in that series, setting series: my-new-series
This is either the number in the series or the number in the volume.
This field is required if series is present.
papers and excerpts must have either booktitle OR from_book set.
from_book takes a monograph slug and booktitle takes a simple string.
Either a page count or a page range.
If this is a journal article or book excerpt, specify the page range in the format pages: "5--24".
For other written works, specify the number of ~A4-sized pages it would take to print the work.
For example, a 100-page, A5-sized booklet should have pages: 50
This field is required for all works other than reference, av and canon.
The chapter number for an excerpt or paper if known.
The duration of an Audio/Video recording.
This field must be a whole number of minutes and is required for all av items.
This line tells Jekyll that the Yaml data is over and we're ready to start supplying Markdown.
The typical item in the library starts with a catchy pull quote from the work and then has a description of the work, in the form:
> It was the best of times,
> it was the worst of times...
A book about some specific topic
recommended for people interested in
some particular question or dilemma.Crafting this prose is more art than science, but know that the first paragraph will get featured independently on the tag pages. If the pull quote is e.g. from the abstract and summarizes the work well, the prose description may sometimes be omitted and the number of pull quotes can sometimes vary as well.
Below these paragraphs is the place to add links to additional information, related works, etc.
Once you're satisfied with your new addition(s), put up a PR and Khemarato Bhikkhu will review it!
Any questions not answered here? Feel free to email me