Merge pull request #5585 from StackOverflowExcept1on/update-corosensei #1343
This file contains hidden or 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: Documentation | |
on: | |
push: | |
branches: | |
- 'main' | |
paths: | |
- 'lib/**' | |
env: | |
MSRV: "1.81" | |
jobs: | |
documentation: | |
name: Documentation | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install Rust | |
uses: dtolnay/rust-toolchain@stable | |
with: | |
toolchain: ${{ env.MSRV }} | |
- name: Install LLVM | |
shell: bash | |
run: | | |
curl --proto '=https' --tlsv1.2 -sSf ${{ env.LLVM_URL }} -L -o llvm.tar.xz | |
mkdir ${{ env.LLVM_DIR }} | |
tar xf llvm.tar.xz --strip-components=1 -C ${{ env.LLVM_DIR }} | |
echo "${{ env.LLVM_DIR }}/bin" >> $GITHUB_PATH | |
echo "LLVM_SYS_180_PREFIX=${{ env.LLVM_DIR }}" >> $GITHUB_ENV | |
env: | |
LLVM_DIR: ${{ github.workspace }}/llvm-18 | |
LLVM_URL: 'https://github.com/wasmerio/llvm-custom-builds/releases/download/18.x/llvm-linux-amd64.tar.xz' | |
- name: Build & package documentation | |
run: make package-docs | |
- name: Publish documentation | |
uses: peaceiris/actions-gh-pages@v3 | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
publish_dir: ./package/docs |