Skip to content

Commit

Permalink
ci: require docs to be fine
Browse files Browse the repository at this point in the history
Build the documentation as part of PRs. Fail when something wrong is
found while building the docs.

Signed-off-by: Flavio Castelli <fcastelli@suse.com>
  • Loading branch information
flavio committed May 23, 2024
1 parent 4076349 commit 906b5f6
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 1 deletion.
13 changes: 13 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,19 @@ jobs:
command: test
args: --workspace --features full-native-tls,test-registry

doc:
name: Build Documentation
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6
- uses: actions-rs/toolchain@16499b5e05bf2e26879000db0c1d13f7e13fa3af # v1.0.7
with:
profile: minimal
toolchain: nightly
override: true
- run: |
make doc
fmt:
name: Rustfmt
runs-on: ubuntu-latest
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ lint:

.PHONY: doc
doc:
cargo doc
RUSTDOCFLAGS="--cfg docsrs -D warnings" cargo +nightly doc --all-features --no-deps

.PHONY: test
test: fmt lint doc
Expand Down

0 comments on commit 906b5f6

Please sign in to comment.