| 1 |
name: rustdoc |
| 2 |
on: |
| 3 |
push: |
| 4 |
branches: |
| 5 |
- main |
| 6 |
|
| 7 |
env: |
| 8 |
CARGO_INCREMENTAL: 0 |
| 9 |
CARGO_NET_RETRY: 10 |
| 10 |
RUSTUP_MAX_RETRIES: 10 |
| 11 |
|
| 12 |
jobs: |
| 13 |
rustdoc: |
| 14 |
runs-on: ubuntu-latest |
| 15 |
|
| 16 |
steps: |
| 17 |
- name: Checkout repository |
| 18 |
uses: actions/checkout@v2 |
| 19 |
|
| 20 |
- name: Install Rust toolchain |
| 21 |
uses: actions-rs/toolchain@v1 |
| 22 |
with: |
| 23 |
toolchain: stable |
| 24 |
profile: minimal |
| 25 |
override: true |
| 26 |
components: rustfmt, rust-src |
| 27 |
|
| 28 |
- name: Build Documentation |
| 29 |
run: cargo doc --all --all-features |
| 30 |
|
| 31 |
- name: Deploy Docs |
| 32 |
uses: peaceiris/actions-gh-pages@364c31d33bb99327c77b3a5438a83a357a6729ad # v3.4.0 |
| 33 |
with: |
| 34 |
github_token: ${{ secrets.GITHUB_TOKEN }} |
| 35 |
publish_branch: gh-pages |
| 36 |
publish_dir: ./target/doc |
| 37 |
force_orphan: true |