Skip to content

Commit

Permalink
Run CI checks for Rust 2024 as well
Browse files Browse the repository at this point in the history
  • Loading branch information
samueltardieu committed Oct 30, 2024
1 parent 4691131 commit 189b5f5
Showing 1 changed file with 39 additions and 2 deletions.
41 changes: 39 additions & 2 deletions .github/workflows/clippy_dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,43 @@ jobs:
cargo check
git reset --hard HEAD
clippy_dev_2024:
runs-on: ubuntu-latest

steps:
# Setup
- name: Checkout
uses: actions/checkout@v4

- name: Select Rust 2024 edition
run: |
for i in clippy_config clippy_dev clippy_lints clippy_utils lintcheck; do
sed -i \
-e '1icargo-features = ["edition2024"]\n' \
-e 's/edition = "2021"/edition = "2024"/' \
$i/Cargo.toml
done
# Run
- name: Build
run: cargo build
working-directory: clippy_dev

- name: Test update_lints
run: cargo dev update_lints --check

- name: Test fmt
run: cargo dev fmt --check

- name: Test cargo dev new lint
env:
RUSTFLAGS: -A unused-imports
run: |
cargo dev new_lint --name new_early_pass --pass early
cargo dev new_lint --name new_late_pass --pass late
cargo check
git reset --hard HEAD
# These jobs doesn't actually test anything, but they're only used to tell
# bors the build completed, as there is no practical way to detect when a
# workflow is successful listening to webhooks only.
Expand All @@ -57,7 +94,7 @@ jobs:
name: bors dev test finished
if: github.event.pusher.name == 'bors' && success()
runs-on: ubuntu-latest
needs: [clippy_dev]
needs: [clippy_dev, clippy_dev_2024]

steps:
- name: Mark the job as successful
Expand All @@ -67,7 +104,7 @@ jobs:
name: bors dev test finished
if: github.event.pusher.name == 'bors' && (failure() || cancelled())
runs-on: ubuntu-latest
needs: [clippy_dev]
needs: [clippy_dev, clippy_dev_2024]

steps:
- name: Mark the job as a failure
Expand Down

0 comments on commit 189b5f5

Please sign in to comment.