Skip to content

Commit

Permalink
Add README, get documentation build working.
Browse files Browse the repository at this point in the history
  • Loading branch information
hcayless committed Jul 2, 2024
1 parent e558c02 commit 57b88c2
Show file tree
Hide file tree
Showing 9 changed files with 83 additions and 19 deletions.
3 changes: 3 additions & 0 deletions .eleventy.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,9 @@ module.exports = function(eleventyConfig) {

eleventyConfig.addFilter("isoDateToPath",
function(date) {
if (date instanceof Date) {
date = date.toISOString().replace(/:.*$/, "").replace(/T.*$/, "");
}
return date.replace(/-/g, "/");
}
);
Expand Down
1 change: 1 addition & 0 deletions .eleventyignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
README.md
dist
node_modules
src/documentation/Documentation/Bylaws
Expand Down
61 changes: 61 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
# The TEI-C website source

This repository contains the sources for the TEI website and the configuration to run it locally if you need to. If you are editing the website's content, you will only need to be focused on the contents of the `src/` directory, which is laid out like this:

```txt
src
├── _data
├── _includes
├── _layouts
├── about
│   └── logos
│   └── potential-new-logos
├── activities
│   └── projects
├── assets
│   ├── css
│   ├── img
│   └── js
├── documentation
│   └── Documentation
│   ├── Bylaws
│   ├── TCW
│   └── bin
├── guidelines
├── news
│   ├── 2023
│   │   ├── 01
│   │   │   ├── 09
│   │   │   └── 28
│   │   ├── 02
│   │   │   └── 27
│   │   ├── 08
│   │   │   ├── 02
│   │   │   └── 06
│   │   └── 09
│   │   └── 24
│   └── 2024
├── posts
└── support
└── learn
```

Unless you need to change the look and feel of the site, you can ignore any directory prefixed with a `_`. The `assets/` directory contains CSS, JavaScript, and images.

Content files are mostly written in Markdown. You will notice that each one has a header like

```txt
---
layout: page.njk
title: "Customization"
tags: page
---
```

Most markdown files will use the `page.njk` layout. The title will end up being the header title of the HTML page. In a few cases, as in news posts, you will need to supply a `date` in ISO (year-2-digit month-2-digit day) format. For news posts, the date and title will determine the final URL rather than the folder organization. Older posts may be organized into year, month, and day folders, but that is only because of how they were migrated from the old website. It may be convenient to organize them into folders, but it isn't required.

By default, a file like `src/support.md` will end up being served at a URL like `https://tei-c.org/support`. If you need to change this behavior, you can set the `permalink` property in the header to the URL you desire.

The TEI Documentation pages are an exception. These are included as a Git submodule in `src/documentation/Documentation` and are TEI files. You probably don't want to edit them locally, but if you do, make sure they get pushed to the Documentation repo.

The root index pages, `index.en.md` and `index.es.md` are special in that they are set up for the Apache web server to do content negotiation to determine whether to show an English or Spanish version of the landing page depending on the requester's locale. If you use the built in Eleventy serve command, be aware that you won't get a regular index.html file at the root.
2 changes: 1 addition & 1 deletion src/documentation/Documentation
10 changes: 10 additions & 0 deletions src/documentation/documentation.11tydata.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
module.exports = function() {
return {
"layout": "documentation.njk",
"tags": "Working Papers",
"permalink": data => `${data.page.filePathStem.replace("Documentation/TCW", "").replace(".xml", "/index.html")}`,
"eleventyNavigation": {
"parent": "Council"
}
}
}
7 changes: 0 additions & 7 deletions src/documentation/tcw.json

This file was deleted.

5 changes: 0 additions & 5 deletions src/news/2023/tei-2024-website-live.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,19 +2,14 @@
layout: page.njk
title: "TEI 2024 website live!"
date: "2023-12-21"
permalink: /news/{{date | isoDateToPath}}/{{title | slugify}}
tags: news
---
# TEI 2024 website live!
TEI 2024, the twenty-fourth conference of the [Text Encoding Initiative](https://tei-c.org/), will be held in Buenos Aires, Argentina - the first TEI conference to take place in a Spanish-speaking country. Texts, Languages, and Communities will take place in Buenos Aires, Argentina at [Universidad del Salvador](https://www.google.com/maps/place/Universidad+del+Salvador+-+Rectorado/@-34.6013439,-58.3941206,17z/data=!3m1!4b1!4m6!3m5!1s0x95bccbbceb753a91:0xe6208305d17821e1!8m2!3d-34.6013439!4d-58.3915457!16zL20vMDkwbV92?authuser=6&entry=ttu), 7-11 October 2024.


The conference website is now live and can be accessed [here](https://tei2024.tei-c.org/). The Call for Papers will be announced in February 2024.


Conference organizers can be reached via the website '[Contact](https://tei2024.tei-c.org/contact)' page.


We look forward to seeing you in Buenos Aires in October! / ¡Esperamos verte en Buenos Aires en octubre!


7 changes: 7 additions & 0 deletions src/news/news.11tydata.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
module.exports = function() {
return {
permalink: function(data) {
return `/news/${this.isoDateToPath(data.date)}/${this.slugify(data.title)}/index.html`;
},
}
}
6 changes: 0 additions & 6 deletions src/tools.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,6 @@ tags: page
---
# Tools







Tools for creating, editing, transforming, and publishing TEI documents and schemas
are essential to using the TEI Guidelines. Since the TEI rules and recomendations
are expressed in XML, TEI users can take advantage of the abundance of XML tools developed
Expand Down

0 comments on commit 57b88c2

Please sign in to comment.