Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
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
21 changes: 21 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,27 @@ jobs:
# silently ignored the fork we install above and built with upstream
# mystmd (visible as 23 `unknown export output extension: *.ipynb`
# errors, since ipynb export is a fork-only capability).
# Build the theme from per-page-thebe (adds enable_thebe/disable_thebe/
# default_thebe support). Remove this step once the feature ships in a
# tagged release and the template URL below is bumped to that release.
- name: Build theme (per-page-thebe)
run: |
git clone --depth 1 --branch per-page-thebe \
https://github.com/QuantEcon/quantecon-theme.mystmd.git /tmp/qe-theme
cd /tmp/qe-theme && npm ci && make build-theme
# Patch myst.yml to use the local build instead of the release zip.
python -c "
import re, os
path = os.path.join(os.environ['GITHUB_WORKSPACE'], 'lectures/myst.yml')
txt = open(path).read()
txt = re.sub(
r'template: https://github\.com/QuantEcon/quantecon-theme\.mystmd/releases/download/[^\n]+',
'template: /tmp/qe-theme/.deploy/quantecon-theme',
txt
)
open(path, 'w').write(txt)
"

- name: Build HTML
working-directory: ./lectures
env:
Expand Down
2 changes: 2 additions & 0 deletions lectures/functions.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ downloads:
title: Markdown (md)
- file: exports/functions.ipynb
title: IPython (.ipynb)
site:
enable_thebe: true
---

# Functions
Expand Down
2 changes: 2 additions & 0 deletions lectures/matplotlib.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ downloads:
title: Markdown (md)
- file: exports/matplotlib.ipynb
title: IPython (.ipynb)
site:
enable_thebe: true
---

# Matplotlib
Expand Down
5 changes: 5 additions & 0 deletions lectures/myst.yml
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,8 @@ project:
error_rules:
- rule: reference-syntax-valid
severity: ignore
jupyter:
lite: true
# exports:
# - id: book-pdf
# format: typst
Expand Down Expand Up @@ -109,3 +111,6 @@ site:
launch_notebook_repo: QuantEcon/lecture-python-programming.notebooks
launch_notebook_source_dir: lectures
launch_colab: true
# Opt-in mode: Power toggle is hidden site-wide; only pages that set
# `site: enable_thebe: true` in their frontmatter show it.
default_thebe: false
Loading