Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
622d9fc
Migrate site build from Jekyll to Pelican
devinsilvia May 5, 2026
6dc1d08
Replace shell-based pubs script with pure-Python implementation
devinsilvia May 5, 2026
c068e5b
Updating the README to align with the new Pelican workflow (pure python,
devinsilvia May 5, 2026
be2dc03
Removing the old files needed for the Jekyll-based workflow
devinsilvia May 5, 2026
9b3da3f
Adding a .nojekyll file to prevent GitHub pages from trying to autobu…
devinsilvia May 5, 2026
ddfeab2
Adding a deploy.yml file for GitHub Actions to build the site
devinsilvia May 5, 2026
ba02e76
Modifying the publication generation scripted process to use a local …
devinsilvia May 6, 2026
b01c964
Fix canonical URL, static paths, and publish config path anchoring
devinsilvia May 6, 2026
9198f8c
Minor cleanup: caching, encoding, dead config, and docs corrections
devinsilvia May 6, 2026
a4e1447
Remove dead code and suppress unfinished about page
devinsilvia May 6, 2026
341945d
Add dark mode support via prefers-color-scheme media query
devinsilvia May 6, 2026
f382888
Add dark mode squirrel logo via picture element
devinsilvia May 6, 2026
e0080a3
Add News & Perspectives section
devinsilvia May 6, 2026
f023211
Add News & Perspectives post documentation to README and CLAUDE.md
devinsilvia May 7, 2026
65220a5
Tweaking the local serving command in the README
devinsilvia May 7, 2026
235d35a
Update homepage description, nav order, and people page layout
devinsilvia May 7, 2026
f5a328a
Tweaking the deploy.yml file to see if I can trigger a build
devinsilvia May 7, 2026
49d3ce4
Addressing a Node.js deprecation warning
devinsilvia May 7, 2026
725cb6f
Clean up docs and dead code ahead of merge
devinsilvia May 7, 2026
a6a69ce
Improve accessibility styles and harden uv install guidance
Copilot May 7, 2026
04a1267
Address SEO canonicals, heading cascade, and autoreload docs
Copilot May 7, 2026
4c35fd9
Improve accessibility: skip link, aria-current, heading hierarchy
devinsilvia May 7, 2026
010ad0c
Further accessibility improvements to templates and CSS
devinsilvia May 7, 2026
a1b2885
Fix active nav link contrast to meet WCAG AA
devinsilvia May 7, 2026
63030c4
Fix link contrast and accessibility in body and aside
devinsilvia May 7, 2026
5d55e0d
Harden CI, broaden static paths, and fix remaining accessibility gaps
devinsilvia May 7, 2026
9e34a71
Fix news summary wrapper to avoid nested paragraph markup
Copilot May 7, 2026
9a015b6
Add missing h1 to homepage template
devinsilvia May 7, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
58 changes: 58 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
name: Build and Deploy

on:
push:
branches: ["**"]
workflow_dispatch:

permissions:
contents: read
pages: write
id-token: write

env:
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true

concurrency:
group: pages
cancel-in-progress: false

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Install uv
uses: astral-sh/setup-uv@v5
with:
enable-cache: true

- name: Install dependencies
run: uv sync --frozen

- name: Generate publications page
run: uv run python bin/create_pubs.py

- name: Build site
run: uv run pelican content -s publishconf.py

- name: Copy CNAME to output
run: cp CNAME output/

- name: Upload Pages artifact
uses: actions/upload-pages-artifact@v3
with:
path: output/

deploy:
needs: build
if: github.ref == 'refs/heads/main'
runs-on: ubuntu-latest
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
6 changes: 6 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,7 @@
.DS_Store
.venv/
output/
__pycache__/
*.pyc
cache/
.pelican_cache/
Empty file added .nojekyll
Empty file.
9 changes: 0 additions & 9 deletions 404.md

This file was deleted.

138 changes: 138 additions & 0 deletions CLAUDE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,138 @@
# CLAUDE.md

This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.

## What This Is

Pelican static site for the MSU Computing Education Research Lab, hosted on GitHub Pages at `msucerl.org`. The Python environment is managed with `uv`. Pushing to `main` triggers automatic GitHub Pages build and deploy.

## Local Development

```bash
uv sync # install / sync dependencies
uv run pelican content -s pelicanconf.py # one-shot build → output/
uv run pelican --listen --autoreload # build + live-reload dev server
```

For a production build (sets `SITEURL`, deletes `output/` first):

```bash
uv run pelican content -s publishconf.py
```

## Site Architecture

Static pages live under `content/pages/` and news posts under `content/posts/`, all as Markdown files with Pelican metadata headers (plain `Key: Value` lines, no YAML fences). The custom theme is in `themes/`.

**Content pages:**

- `content/pages/home.md` — homepage (uses `index.html` template with aside sidebar)
- `content/pages/people.md` — group roster (most commonly edited)
- `content/pages/projects.md` — active research projects
- `content/pages/pubs.md` — publications (**auto-generated; do not hand-edit**)
- `content/pages/curriculumdev.md` — curriculum development efforts
- `content/pages/outreach.md` — outreach activities

**News & Perspectives posts:**

- `content/posts/` — one Markdown file per post; served at `/news/{year}/{slug}/`

**Theme (`themes/`):**

- `templates/base.html` — shared header/footer, nav, canonical link
- `templates/index.html` — extends base; adds aside sidebar
- `templates/page.html` — extends base; standard content page
- `templates/news.html` — news index listing all posts
- `templates/article.html` — individual post page
- `static/css/style.css` — layout/typography; no hardcoded colors
- `static/css/theme-msu.css` / `static/css/theme-cerl.css` — color tokens per scheme

**Config:**

- `pelicanconf.py` — development config (no absolute URLs)
- `publishconf.py` — production config (sets `SITEURL`, deletes output)
- `MENUITEMS`, `SITE_DESCRIPTION`, and `COLOR_SCHEME` are all set in `pelicanconf.py`

**Static files:**

`STATIC_PATHS = ["assets"]` in `pelicanconf.py` tells Pelican to copy the entire `content/assets/` directory to `output/assets/`. Any images, PDFs, or other files placed under `content/assets/` will be served. Files outside that directory will not be included in the build.

## Switching the Color Theme

Set `COLOR_SCHEME` in `pelicanconf.py` before building (no need to touch `publishconf.py` — it inherits the value via `from pelicanconf import *`):

```python
COLOR_SCHEME = "msu" # MSU brand colors (Spartan Green)
COLOR_SCHEME = "cerl" # CERL logo colors (teal, grey, black)
```

The value is baked into the theme CSS filename at build time — no JavaScript involved.

## Pelican Page Metadata Format

Each page starts with plain key-value metadata followed by a blank line:

```
Title: Page Title
Slug: url-slug

Content here...
```

The homepage uses two extra keys:

```
Save_as: index.html
Template: index
```

## Adding or Updating People

Edit `content/pages/people.md`. Sections are: Group Leaders → Group Members → External Collaborators → CERL Squirrel Alumni. Each entry follows this pattern:

```markdown
#### Firstname Lastname (pronouns)
<img src="/assets/img/FILENAME.jpg" style="float:left;margin:0 1.25rem 1rem 0" width="120" alt="Firstname Lastname">
Bio text here.
```

Place headshot images in `content/assets/img/`. The `<img>` tag is optional — some members have no photo.

## Writing News & Perspectives Posts

Create a new Markdown file in `content/posts/`. The filename becomes the source file only — the URL is controlled by the `Slug` metadata field.

```
Title: Post Title Here
Date: 2026-01-15
Author: Firstname Lastname
Slug: short-url-slug
Summary: One or two sentences shown on the news index page.

Full post content starts here...
```

- **Title** — displayed as the page heading and linked from the news index
- **Date** — controls sort order and URL path (`/news/{year}/{slug}/`)
- **Author** — optional; shown in the byline on the index and post page
- **Slug** — required; determines the URL (use lowercase-with-hyphens)
- **Summary** — optional but recommended; shown as the excerpt on `/news/`

Posts are automatically listed at `/news/` in reverse chronological order. No other configuration is needed.

## Typogrify

`TYPOGRIFY = True` is set in `pelicanconf.py`. Typogrify post-processes rendered HTML to improve typography (smart quotes, em-dashes, ampersand styling, etc.). This is generally transparent but has one known gotcha: **it will mangle double-quoted HTML attributes** if the attribute value contains characters it interprets as quotation marks. Avoid interpolating Pelican variables directly into double-quoted HTML attributes in templates — use `aria-hidden`, `tabindex`, or other attribute-based approaches instead of `aria-label` when the value contains dynamic text.

## Publications Workflow

Publications are generated from a BibTeX file — do not manually edit `content/pages/pubs.md`.

1. Add new entries to `content/assets/bib/group_publications.bib`
2. Run from anywhere in the repo:

```bash
uv run python bin/create_pubs.py
```

The script uses `pypandoc` (bundled binary, no system install needed) with `--citeproc` to render APA citations, groups them by year descending, and writes `content/pages/pubs.md` with Pelican metadata. `bin/create_pubs.sh` is kept as a reference for the old shell-based workflow.
13 changes: 0 additions & 13 deletions Gemfile

This file was deleted.

162 changes: 0 additions & 162 deletions Gemfile.lock

This file was deleted.

Loading
Loading