ci: remove format check #15
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| on: | |
| push: | |
| branches: [main, master, develop] | |
| pull_request: | |
| branches: [main, master] | |
| env: | |
| CARGO_TERM_COLOR: always | |
| RUST_BACKTRACE: 1 | |
| jobs: | |
| check: | |
| name: Check | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install Rust | |
| uses: dtolnay/rust-toolchain@stable | |
| - name: Cache cargo | |
| uses: Swatinem/rust-cache@v2 | |
| - name: Check | |
| run: cargo check --features nlp | |
| test: | |
| name: Test | |
| runs-on: ${{ matrix.os }} | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| os: [ubuntu-latest, macos-latest] | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install Rust | |
| uses: dtolnay/rust-toolchain@stable | |
| - name: Cache cargo | |
| uses: Swatinem/rust-cache@v2 | |
| - name: Run tests (Linux) | |
| if: runner.os == 'Linux' | |
| run: cargo test --features nlp | |
| - name: Run tests (macOS) | |
| if: runner.os == 'macOS' | |
| run: cargo test --features coreml,nlp | |
| clippy: | |
| name: Clippy | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install Rust | |
| uses: dtolnay/rust-toolchain@stable | |
| with: | |
| components: clippy | |
| - name: Cache cargo | |
| uses: Swatinem/rust-cache@v2 | |
| - name: Clippy | |
| run: cargo clippy --features nlp -- -D warnings | |
| build-macos: | |
| name: Build macOS | |
| runs-on: macos-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install Rust | |
| uses: dtolnay/rust-toolchain@stable | |
| with: | |
| targets: aarch64-apple-darwin | |
| - name: Cache cargo | |
| uses: Swatinem/rust-cache@v2 | |
| - name: Build (x86_64) | |
| run: cargo build --release --features coreml,nlp | |
| - name: Build (aarch64) | |
| run: cargo build --release --target aarch64-apple-darwin --features coreml,nlp | |
| if: runner.arch == 'ARM64' | |
| - name: Check binary size | |
| run: | | |
| ls -lh target/release/airml | |
| echo "Binary size: $(du -h target/release/airml | cut -f1)" | |
| build-linux: | |
| name: Build Linux | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install Rust | |
| uses: dtolnay/rust-toolchain@stable | |
| - name: Cache cargo | |
| uses: Swatinem/rust-cache@v2 | |
| - name: Build | |
| run: cargo build --release --features nlp | |
| - name: Check binary size | |
| run: | | |
| ls -lh target/release/airml | |
| echo "Binary size: $(du -h target/release/airml | cut -f1)" |