|
1 | | -name: Code Quality (rustfmt and clippy) |
2 | | -on: [pull_request, create] |
| 1 | +name: Code Quality |
| 2 | +on: [pull_request] |
3 | 3 |
|
4 | 4 | jobs: |
5 | | - build: |
6 | | - if: github.event_name == 'pull_request' |
7 | | - name: Code Quality (clippy, rustfmt) |
8 | | - runs-on: ubuntu-latest |
9 | | - strategy: |
10 | | - matrix: |
11 | | - rust: |
12 | | - - stable |
13 | | - target: |
14 | | - - x86_64-unknown-linux-gnu |
| 5 | + code-quality-macos: |
| 6 | + name: libkrun (macOS aarch64) |
| 7 | + runs-on: macos-latest |
15 | 8 | steps: |
16 | | - - name: Code checkout |
17 | | - uses: actions/checkout@v2 |
18 | | - - name: Install Rust toolchain (${{ matrix.rust }}) |
19 | | - uses: actions-rs/toolchain@v1 |
20 | | - with: |
21 | | - toolchain: ${{ matrix.rust }} |
22 | | - target: ${{ matrix.target }} |
23 | | - override: true |
24 | | - components: rustfmt, clippy |
25 | | - |
26 | | - - name: Install asciidoctor |
27 | | - run: sudo apt-get install -y asciidoctor |
28 | | - |
29 | | - - name: Install additional Rust rust targets |
30 | | - run: rustup target add aarch64-unknown-linux-gnu aarch64-apple-darwin |
31 | | - |
32 | | - - name: Formatting (rustfmt) |
33 | | - run: cargo fmt -- --check |
34 | | - |
35 | | - - name: Clippy x86_64-unknown-linux-gnu (all features) |
36 | | - run: cargo clippy --all-features --target x86_64-unknown-linux-gnu |
37 | | - |
38 | | - - name: Clippy aarch64-unknown-linux-gnu (all features) |
39 | | - run: cargo clippy --all-features --target aarch64-unknown-linux-gnu |
40 | | - |
41 | | - - name: Clippy aarch64-apple-darwin (all features) |
42 | | - run: cargo clippy --all-features --target aarch64-apple-darwin |
| 9 | + - uses: actions/checkout@v4 |
| 10 | + |
| 11 | + - name: Setup build environment |
| 12 | + uses: ./.github/actions/setup-build-env |
| 13 | + |
| 14 | + - name: Clippy (efi+gpu) |
| 15 | + run: cargo clippy --locked -- -D warnings |
0 commit comments