ct0371-2: Add lesson notes #191
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: mdbook-build | |
on: | |
push: | |
branches: ["master"] | |
pull_request: | |
branches: ["master"] | |
workflow_dispatch: | |
jobs: | |
build: | |
runs-on: ubuntu-22.04 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Setup mdBook | |
uses: peaceiris/actions-mdbook@v1 | |
with: | |
mdbook-version: '0.4.34' | |
- name: Setup Graphviz | |
run: sudo apt-get install -y graphviz fonts-liberation | |
- name: Download the katex preprocessor | |
run: | | |
wget 'https://github.com/lzanini/mdbook-katex/releases/download/v0.5.7/mdbook-katex-v0.5.7-x86_64-unknown-linux-gnu.tar.gz' | |
tar xvf mdbook-katex-v0.5.7-x86_64-unknown-linux-gnu.tar.gz | |
mv -v mdbook-katex ~/.cargo/bin | |
- name: Build the dot preprocessor | |
run: | | |
cargo build --manifest-path deps/mdbook-dot/Cargo.toml | |
cp deps/mdbook-dot/target/debug/mdbook-dot ~/.cargo/bin | |
- name: Build the book files | |
run: mdbook build | |
- name: Deploy to the GitHub Pages branch | |
uses: peaceiris/actions-gh-pages@v3 | |
with: | |
github_token: ${{secrets.GITHUB_TOKEN}} | |
publish_dir: ./book | |
publish_branch: book |