Merge pull request #2508 from subspace/xdm_mmr #1589
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: rustdoc | |
on: | |
push: | |
branches: | |
- main | |
concurrency: | |
group: rustdoc-${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: true | |
env: | |
CARGO_INCREMENTAL: 0 | |
CARGO_NET_RETRY: 10 | |
RUSTUP_MAX_RETRIES: 10 | |
jobs: | |
rustdoc: | |
runs-on: ubuntu-22.04 | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@93ea575cb5d8a053eaa0ac8fa3b40d7e05a33cc8 # @v3.1.0 | |
# TODO: on Linux and Windows, LLVM 16 is not compatible with the consensus/domain runtime build | |
# thus install LLVM 15 explicitly as a temporary workaround, and remove once it is fixed. | |
- name: Install LLVM and Clang | |
uses: KyleMayes/install-llvm-action@c135b3937686fd69c2651507aabc9925a8f9eee8 # v1.8.3 | |
with: | |
version: "15.0" | |
- name: Install Protoc | |
uses: arduino/setup-protoc@9b1ee5b22b0a3f1feb8c2ff99b32c89b3c3191e9 # v2.0.0 | |
with: | |
repo-token: ${{ secrets.GITHUB_TOKEN }} | |
- name: Configure cache | |
uses: actions/cache@704facf57e6136b1bc63b828d79edcd491f0ee84 # @v3.3.2 | |
with: | |
path: | | |
~/.cargo/registry | |
~/.cargo/git | |
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.toml') }} | |
restore-keys: | | |
${{ runner.os }}-cargo- | |
# Build the rust crate docs | |
- name: Build Documentation | |
run: cargo -Zgitoxide -Zgit doc --all --no-deps --lib | |
env: | |
RUSTDOCFLAGS: "-Z unstable-options --enable-index-page" | |
- name: Deploy Docs | |
uses: JamesIves/github-pages-deploy-action@ba1486788b0490a235422264426c45848eac35c6 # @v4.4.1 | |
with: | |
branch: gh-pages | |
folder: target/doc |