mirror of
https://github.com/tower-rs/tower.git
synced 2026-01-19 15:21:40 +00:00
33 lines
774 B
YAML
33 lines
774 B
YAML
name: Deploy API Documentation
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- master
|
|
|
|
jobs:
|
|
publish:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- name: Checkout code
|
|
uses: actions/checkout@v6
|
|
- name: Install nightly Rust
|
|
uses: dtolnay/rust-toolchain@master
|
|
with:
|
|
toolchain: nightly
|
|
- name: Generate documentation
|
|
run: cargo doc --workspace --no-deps --all-features
|
|
env:
|
|
# Enable the RustDoc `#[doc(cfg(...))]` attribute.
|
|
RUSTDOCFLAGS: --cfg docsrs
|
|
- name: Deploy documentation
|
|
if: success()
|
|
uses: crazy-max/ghaction-github-pages@v1
|
|
with:
|
|
target_branch: gh-pages
|
|
build_dir: target/doc
|
|
env:
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|