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
1 change: 1 addition & 0 deletions .github/workflows/cache.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ on:
push:
branches:
- main

jobs:
tests:
runs-on: ubuntu-latest
Expand Down
98 changes: 51 additions & 47 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,22 +15,22 @@ jobs:
python-version: "3.11"
environment-file: environment.yml
activate-environment: quantecon
- name: Graphics Support #TODO: Review if graphviz is needed
run: |
sudo apt-get -qq update && sudo apt-get install -y graphviz
- name: Install latex dependencies
run: |
sudo apt-get -qq update
sudo apt-get install -y \
texlive-latex-recommended \
texlive-latex-extra \
texlive-fonts-recommended \
texlive-fonts-extra \
texlive-xetex \
latexmk \
xindy \
dvipng \
cm-super
# - name: Graphics Support #TODO: Review if graphviz is needed
# run: |
# sudo apt-get -qq update && sudo apt-get install -y graphviz
# - name: Install latex dependencies
# run: |
# sudo apt-get -qq update
# sudo apt-get install -y \
# texlive-latex-recommended \
# texlive-latex-extra \
# texlive-fonts-recommended \
# texlive-fonts-extra \
# texlive-xetex \
# latexmk \
# xindy \
# dvipng \
# cm-super
- name: Display Conda Environment Versions
shell: bash -l {0}
run: conda list
Expand All @@ -41,49 +41,53 @@ jobs:
uses: dawidd6/action-download-artifact@v6
with:
workflow: cache.yml
branch: main
branch: cache_test_3
name: build-cache
path: _build
# Build Assets (Download Notebooks and PDF via LaTeX)
- name: Build PDF from LaTeX
shell: bash -l {0}
run: |
jb build lectures --builder pdflatex --path-output ./ -n --keep-going
mkdir -p _build/html/_pdf
cp -u _build/latex/*.pdf _build/html/_pdf
- name: Upload Execution Reports (LaTeX)
uses: actions/upload-artifact@v4
if: failure()
with:
name: execution-reports
path: _build/latex/reports
- name: Build Download Notebooks (sphinx-tojupyter)
shell: bash -l {0}
run: |
jb build lectures --path-output ./ --builder=custom --custom-builder=jupyter
mkdir -p _build/html/_notebooks
cp -u _build/jupyter/*.ipynb _build/html/_notebooks
# # Build Assets (Download Notebooks and PDF via LaTeX)
# - name: Build PDF from LaTeX
# shell: bash -l {0}
# run: |
# jb build lectures --builder pdflatex --path-output ./ -n --keep-going
# mkdir -p _build/html/_pdf
# cp -u _build/latex/*.pdf _build/html/_pdf
# - name: Upload Execution Reports (LaTeX)
# uses: actions/upload-artifact@v4
# if: failure()
# with:
# name: execution-reports
# path: _build/latex/reports
# - name: Build Download Notebooks (sphinx-tojupyter)
# shell: bash -l {0}
# run: |
# jb build lectures --path-output ./ --builder=custom --custom-builder=jupyter
# mkdir -p _build/html/_notebooks
# cp -u _build/jupyter/*.ipynb _build/html/_notebooks
# Build HTML (Website)
# BUG: rm .doctress to remove `sphinx` rendering issues for ipywidget mimetypes
# and clear the sphinx cache for building final HTML documents.
- name: Build HTML
shell: bash -l {0}
run: |
rm -r _build/.doctrees
ls
cd _build
ls
cd ..
jb build lectures --path-output ./ -nW --keep-going

- name: Upload Execution Reports (HTML)
uses: actions/upload-artifact@v4
if: failure()
with:
name: execution-reports
path: _build/html/reports
- name: Preview Deploy to Netlify
uses: nwtgck/actions-netlify@v3.0
with:
publish-dir: '_build/html/'
production-branch: main
github-token: ${{ secrets.GITHUB_TOKEN }}
deploy-message: "Preview Deploy from GitHub Actions"
env:
NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }}
NETLIFY_SITE_ID: ${{ secrets.NETLIFY_SITE_ID }}
# - name: Preview Deploy to Netlify
# uses: nwtgck/actions-netlify@v3.0
# with:
# publish-dir: '_build/html/'
# production-branch: main
# github-token: ${{ secrets.GITHUB_TOKEN }}
# deploy-message: "Preview Deploy from GitHub Actions"
# env:
# NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }}
# NETLIFY_SITE_ID: ${{ secrets.NETLIFY_SITE_ID }}
20 changes: 10 additions & 10 deletions environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,17 +7,17 @@ dependencies:
- anaconda=2024.06
- pip
- pip:
- jupyter-book==0.15.1
- docutils==0.17.1
- jupyter-book
- docutils
- quantecon-book-theme==0.7.2
- sphinx-tojupyter==0.3.0
- sphinxext-rediraffe==0.2.7
- sphinx-exercise==0.4.1
- sphinx-proof==0.2.0
- ghp-import==1.1.0
- sphinxcontrib-youtube==1.1.0
- sphinx-togglebutton==0.3.1
- sphinx_reredirects==0.1.3
- sphinx-tojupyter
- sphinxext-rediraffe
- sphinx-exercise
- sphinx-proof
- ghp-import
- sphinxcontrib-youtube
- sphinx-togglebutton
- sphinx_reredirects
# Sandpit Requirements
# - PuLP
# - cvxpy
Expand Down
1 change: 0 additions & 1 deletion lectures/_config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,6 @@ sphinx:
width: 80%
nb_code_prompt_show: "Show {type}"
suppress_warnings: [mystnb.unknown_mime_type, myst.domains]
proof_minimal_theme: true
# -------------
html_js_files:
- https://cdnjs.cloudflare.com/ajax/libs/require.js/2.3.4/require.min.js
Expand Down
1 change: 1 addition & 0 deletions lectures/about.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ This lecture series introduces quantitative economics using elementary
mathematics and statistics plus computer code written in
[Python](https://www.python.org/).


The lectures emphasize simulation and visualization through code as a way to
convey ideas, rather than focusing on mathematical details.

Expand Down