mirror of https://github.com/zcash/halo2.git
50 lines
1.2 KiB
YAML
50 lines
1.2 KiB
YAML
name: halo2 book
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- main
|
|
|
|
jobs:
|
|
deploy:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v3
|
|
- uses: actions-rs/toolchain@v1
|
|
with:
|
|
toolchain: nightly
|
|
override: true
|
|
|
|
- name: Setup mdBook
|
|
uses: peaceiris/actions-mdbook@v1
|
|
with:
|
|
mdbook-version: 'latest'
|
|
|
|
- name: Install mdbook-katex
|
|
uses: actions-rs/cargo@v1
|
|
with:
|
|
command: install
|
|
args: mdbook-katex
|
|
|
|
- name: Build halo2 book
|
|
run: mdbook build book/
|
|
|
|
- name: Build latest rustdocs
|
|
uses: actions-rs/cargo@v1
|
|
with:
|
|
command: doc
|
|
args: --no-deps --workspace --all-features
|
|
env:
|
|
RUSTDOCFLAGS: -Z unstable-options --enable-index-page --cfg docsrs --html-in-header ${{ github.workspace }}/halo2_proofs/katex-header.html
|
|
|
|
- name: Move latest rustdocs into book
|
|
run: |
|
|
mkdir -p ./book/book/rustdoc
|
|
mv ./target/doc ./book/book/rustdoc/latest
|
|
|
|
- name: Deploy to GitHub Pages
|
|
uses: peaceiris/actions-gh-pages@v3
|
|
with:
|
|
github_token: ${{ secrets.GITHUB_TOKEN }}
|
|
publish_dir: ./book/book
|