Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add cargo documentation checks #12

Merged
merged 1 commit into from
Jul 1, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 24 additions & 7 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ env:
CARGO_TERM_COLOR: always
# A job fails if any Rust warnings are emitted.
RUSTFLAGS: "-Dwarnings"
RUSTDOCFLAGS: "-Dwarnings"

jobs:
build-debug:
Expand All @@ -21,9 +22,9 @@ jobs:
- name: Checkout
uses: actions/checkout@v4
- name: Build
run: cargo build --verbose
run: cargo build --workspace --verbose
- name: Test
run: cargo test --verbose
run: cargo test --workspace --verbose

build-release:
name: build-release-${{ matrix.os }}
Expand All @@ -36,30 +37,46 @@ jobs:
- name: Checkout
uses: actions/checkout@v4
- name: Build
run: cargo build --verbose --release
run: cargo build --workspace --verbose --release
- name: Test
run: cargo test --verbose --release
run: cargo test --workspace --verbose --release

doc:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Check formatting
run: cargo doc --workspace --verbose --document-private-items

doc-test:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Check formatting
run: cargo test --workspace --verbose --doc

fmt:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Check formatting
run: cargo fmt --verbose --check
run: cargo fmt --all --verbose --check

lint:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Clippy
run: cargo clippy --verbose --all-targets --all-features
run: cargo clippy --workspace --verbose --all-targets --all-features

package:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Package
run: cargo package --verbose --all-features
run: cargo package --workspace --verbose --all-features