Skip to content

update a3 deadline

update a3 deadline #24

Workflow file for this run

name: deploy-book
# Only run this when the master branch changes
on:
push:
branches:
- main
# If your git repository has the Jupyter Book within some-subfolder next to
# unrelated files, you can make this run only if a file within that specific
# folder has been modified.
#
# paths:
# - some-subfolder/**
# This job installs dependencies, build the book, and pushes it to `gh-pages`
jobs:
deploy-book:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
# Install dependencies
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: 3.8
- uses: actions/cache@v3
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }}
restore-keys: |
${{ runner.os }}-pip-
- name: Install dependencies
run: |
pip install -r requirements.txt
- name: Restore cached build
id: cache-build-restore
uses: actions/cache/restore@v3
with:
path: |
_build/html/
key: ${{ runner.os }}-build
# Build the whole webste
- name: Build the whole website
run: |
jupyter-book build . --builder pdfhtml
mv _build/pdf/book.pdf _build/html/coursemanual.pdf
jupyter-book build .
# Build the syllabus only
- name: Build the syllabus pdf and save with the rest
run: |
cd syllabus/
jupyter-book build . --toc _toc_syllabus.yml --builder pdfhtml --all
mv _build/pdf/book.pdf ../_build/html/syllabus.pdf
- name: Save Build
id: cache-build-save
uses: actions/cache/save@v3
with:
path: |
_build/html
key: ${{ steps.cache-build-restore.outputs.cache-primary-key }}
# Push the book's HTML to github-pages
- name: GitHub Pages action
uses: peaceiris/actions-gh-pages@v3.6.1
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./_build/html