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

split rustfmt and clippy checks into separate jobs #472

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft
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
29 changes: 17 additions & 12 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,21 +42,26 @@ jobs:
- name: Execute cargo build
run: |
cargo build --manifest-path=./graphql_client/Cargo.toml --features="reqwest" --target wasm32-unknown-unknown

rustfmt:
name: Rustfmt
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
- run: cargo fmt --all -- --check

lint:
name: Rustfmt and Clippy
name: Clippy
runs-on: ubuntu-latest
if: github.repository == 'graphql-rust/graphql-client'
steps:
- name: Checkout sources
uses: actions/checkout@v4
- name: Install toolchain
uses: dtolnay/rust-toolchain@stable
with:
components: clippy,rustfmt
- name: Execute cargo fmt
run: cargo fmt --all -- --check
- name: Execute cargo clippy
run: cargo clippy --all --all-targets --all-features -- -D warnings
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@master
with:
toolchain: nightly-2024-01-10
components: clippy
- run: cargo clippy --all --all-targets --all-features -- -D warnings

prettier:
name: Check prettier
runs-on: ubuntu-latest
Expand Down
Loading