This repository contains the source code for the CS312 website.
Course-design and content work is tracked in issues,
organised by area (area:lectures, area:labs, ...) and by kind of work
(type:content, type:decision, ...). The Next Iteration milestone holds what is
committed for the next offering; Backlog holds what is wanted but not yet scheduled.
Found a typo, a broken link, or an instruction that does not work? Please open an issue.
The per-term instructor checklist lives in
.github/ISSUE_TEMPLATE/term-setup.md;
open a fresh copy of it at the start of each term.
The scripts/generate-pdfs.sh helper will retrieve and generate individual PDFs for all lectures, studios, assignments, and practicalities from the live deployment. It will then generate a combined version of all files. To run it, use:
cd scripts
chmod +x ./generate-pdfs.sh
./generate-pdfs.shYou can change the BASE variable in the script to point to a different deployment if needed.
To generate slides from marp, use:
cd slides
bun x @marp-team/marp-cli@latest intro.md --pdf --allow-local-filesTo generate a PDF from a single MD file, use:
# TODO: improve because this is very average
pandoc input.md --pdf-engine=wkhtmltopdf -V margin=1in -o output.pdfInside of your Astro + Starlight project, you'll see the following folders and files:
.
โโโ .claude/
โ โโโ skills/
โโโ .github/
โ โโโ ISSUE_TEMPLATE/
โโโ canvas/
โโโ public/
โโโ scripts/
โโโ slides/
โโโ src/
โ โโโ assets/
โ โโโ components/
โ โโโ content/
โ โ โโโ docs/
โ โ โโโ config.ts
โ โโโ env.d.ts
โโโ astro.config.mjs
โโโ package.json
โโโ tsconfig.json
Important directories and files include:
.claude/skills/: authoring skills that define the house style for lectures, labs, activities, and assignmentscanvas/: assets for Canvas LMS (TSV rubrics, HTML assignments). The assignment pages import these TSVs at build time, so they are not optionalscripts/: helper scripts for generating PDFs, etc.slides/: slide decks for lectures in Marp Markdown formatsrc/content/docs/: all lecture notes, studios, assignments, practicalities, and other documentation, inmdxformatsrc/components/: reusable components for assignments and lectures, including a LaTeX component, and reactive Svelte components for assignmentsastro.config.mjs: Astro configuration file, update sidebar entries here
All commands are run from the root of the project, from a terminal:
| Command | Action |
|---|---|
bun install |
Installs dependencies |
bun run dev |
Starts local dev server at localhost:4321 |
bun run build |
Build your production site to ./dist/ |
bun run preview |
Preview your build locally, before deploying |
bun run astro ... |
Run CLI commands like astro add, astro check |
bun run astro -- --help |
Get help using the Astro CLI |
- Starlight Getting Started -- Astro template
- TailwindCSS -- for styling
- Svelte -- for reactive components
- Starlight Page Actions, or alternatively Starlight Contextual Menu
- Starlight Links Validator
- How to create an Astro LaTeX component -- LaTeX component
- KaTeX: The fastest math typesetting library for the web. -- LaTeX component
- Mermaid User Guide -- Mermaid component
Licensed under Creative Commons Attribution-ShareAlike 4.0 International (CC BY-SA 4.0). See LICENSE.
You may share and adapt this material, including commercially, provided you give appropriate credit and license your adaptations under the same terms.