Skip to content
Snippets Groups Projects
Commit 8497427c authored by Lukas Kluft's avatar Lukas Kluft
Browse files

Merge branch 'sidenav' into 'main'

change sidenav to explicit listing of lectures

See merge request !20
parents f05ec6dc 152f6a69
No related branches found
No related tags found
1 merge request!20change sidenav to explicit listing of lectures
Pipeline #63112 passed
...@@ -17,3 +17,16 @@ quarto preview --no-navigate ...@@ -17,3 +17,16 @@ quarto preview --no-navigate
(if you omit `--no-navigate`, the preview server would automatically navigate to the most recent modified file, which in our case is likely the automatically generated summary file). (if you omit `--no-navigate`, the preview server would automatically navigate to the most recent modified file, which in our case is likely the automatically generated summary file).
Once the preview server is running, please open it in your browser (if it didn't do this automatically) and go on modifying the source files. Once the preview server is running, please open it in your browser (if it didn't do this automatically) and go on modifying the source files.
### Adding new lecture slides
Lecture slides have to be added as a Quarto markdown file to the `lectures` folder.
Specifically, each lecture has to be in a separate subfolder and should be named e.g.: `lectures/example-lecture/slides.qmd`.
Please make sure, that the name of the folder identifies the lecture briefly and does **not** include other information (e.g. the ordering number of the lecture).
You may also check the current `_quarto.yml` for suggestions.
Each slide needs to have a `title` and `author` set in it's [Front Matter](https://quarto.org/docs/authoring/front-matter.html).
Otherwise the file is a Markdown file with special features from [Quarto](https://quarto.org/docs/guide/).
In order to make the new slide deck visible on the lecture website, you'll **also** have to add (or uncomment) the filename of the `website.sidebar.contents` entry in the `_quarto.yml` file.
Please add the file in order of the planned lecture schedule.
...@@ -23,7 +23,23 @@ website: ...@@ -23,7 +23,23 @@ website:
search: true search: true
contents: contents:
- section: "Lectures" - section: "Lectures"
contents: "lectures/[01]*/slides.qmd" contents:
# - "lectures/example-lecture/slides.qmd"
# - "lectures/command-line/slides.qmd"
# - "lectures/git/slides.qmd"
# - "lectures/programming-paradigms/slides.qmd"
# - "lectures/data-structures/slides.qmd"
# - "lectures/complexity/slides.qmd"
# - "lectures/debugging/slides.qmd"
# - "lectures/good-scientific-practice/slides.qmd"
# - "lectures/user-experience/slides.qmd"
# - "lectures/testing/slides.qmd"
# - "lectures/git2/slides.qmd"
# - "lectures/parallelism/slides.qmd"
# - "lectures/hardware/slides.qmd"
# - "lectures/file-and-data-systems/slides.qmd"
# - "lectures/memory-hierarchies/slides.qmd"
# - "lectures/student-talks/slides.qmd"
format: format:
......
...@@ -7,3 +7,4 @@ requests ...@@ -7,3 +7,4 @@ requests
aiohttp aiohttp
zarr zarr
matplotlib matplotlib
pyyaml
import glob
import logging import logging
import yaml
logging.basicConfig() logging.basicConfig()
logging.getLogger().setLevel(logging.DEBUG) logging.getLogger().setLevel(logging.DEBUG)
...@@ -24,7 +24,14 @@ title: "Lecture Overview" ...@@ -24,7 +24,14 @@ title: "Lecture Overview"
def generate_summary(): def generate_summary():
files = sorted(glob.glob("lectures/[01]*/slides.qmd")) project_config = yaml.safe_load(open("_quarto.yml"))
files = [
fn
for s in project_config["website"]["sidebar"]["contents"]
if s.get("section") == "Lectures"
for fn in s["contents"] or []
]
all_entries = [] all_entries = []
for x in files: for x in files:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment