Auto merge of #3287 - gennyble:main, r=JohnTitor #14
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: Upload documentation to GitHub Pages | |
on: | |
push: | |
branches: | |
- main | |
# Sets permissions of `GITHUB_TOKEN` to allow deployment to GitHub Pages | |
permissions: | |
contents: read | |
pages: write | |
id-token: write | |
jobs: | |
deploy: | |
environment: | |
name: github-pages | |
url: ${{ steps.deployment.outputs.page_url }} | |
runs-on: ubuntu-22.04 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Setup Rust toolchain | |
run: TARGET=x86_64-unknown-linux-gnu sh ./ci/install-rust.sh | |
- name: Generate documentation | |
run: LIBC_CI=1 sh ci/dox.sh | |
- name: Setup Pages | |
uses: actions/configure-pages@v3 | |
- name: Fix permissions | |
run: rm -f ./target/doc/.lock | |
- name: Upload artifact | |
uses: actions/upload-pages-artifact@v2 | |
with: | |
path: 'target/doc' | |
- name: Deploy to GitHub Pages | |
id: deployment | |
uses: actions/deploy-pages@v2 |