diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index c7f7274..0679bb6 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -2,13 +2,34 @@ name: Continuous integration on: [push, pull_request] jobs: - ci: + tests: + name: Tests runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - uses: dtolnay/rust-toolchain@stable + - uses: dtolnay/rust-toolchain@1.88 - run: cargo build - run: cargo build --no-default-features - run: cargo test --lib --no-default-features --features english - run: cargo test --lib - run: cargo test --test generate + + checks: + name: Check clippy, formatting, and documentation + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: dtolnay/rust-toolchain@1.88.0 + with: + components: clippy, rustfmt + - run: cargo clippy --workspace --all-targets --all-features + - run: cargo fmt --check --all + - run: cargo doc --workspace --no-deps + + min-version: + name: Check minimum Rust version + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: dtolnay/rust-toolchain@1.64.0 + - run: cargo check --workspace diff --git a/Cargo.toml b/Cargo.toml index 440d7a3..bf6be11 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,7 @@ [package] name = "hypher" version = "0.1.5" +rust-version = "1.64" # also change in ci.yml authors = ["Laurenz "] edition = "2021" description = "hypher separates words into syllables."