feat :: tokenizer, airml options, embed #5
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-action@stable | ||
| - name: Cache cargo | ||
| uses: Swatinem/rust-cache@v2 | ||
| - name: Check | ||
| run: cargo check --all-features | ||
| test: | ||
| name: Test | ||
| runs-on: ${{ matrix.os }} | ||
| strategy: | ||
| fail-fast: false | ||
| matrix: | ||
| os: [ubuntu-latest, macos-latest] | ||
| rust: [stable] | ||
| steps: | ||
| - uses: actions/checkout@v4 | ||
| - name: Install Rust | ||
| uses: dtolnay/rust-action@${{ matrix.rust }} | ||
| - name: Cache cargo | ||
| uses: Swatinem/rust-cache@v2 | ||
| - name: Run tests | ||
| run: cargo test --all-features | ||
| fmt: | ||
| name: Format | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - uses: actions/checkout@v4 | ||
| - name: Install Rust | ||
| uses: dtolnay/rust-action@stable | ||
| with: | ||
| components: rustfmt | ||
| - name: Check formatting | ||
| run: cargo fmt --all -- --check | ||
| clippy: | ||
| name: Clippy | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - uses: actions/checkout@v4 | ||
| - name: Install Rust | ||
| uses: dtolnay/rust-action@stable | ||
| with: | ||
| components: clippy | ||
| - name: Cache cargo | ||
| uses: Swatinem/rust-cache@v2 | ||
| - name: Clippy | ||
| run: cargo clippy --all-features -- -D warnings | ||
| build-macos: | ||
| name: Build macOS | ||
| runs-on: macos-latest | ||
| steps: | ||
| - uses: actions/checkout@v4 | ||
| - name: Install Rust | ||
| uses: dtolnay/rust-action@stable | ||
| with: | ||
| targets: aarch64-apple-darwin | ||
| - name: Cache cargo | ||
| uses: Swatinem/rust-cache@v2 | ||
| - name: Build (x86_64) | ||
| run: cargo build --release | ||
| - name: Build (aarch64) | ||
| run: cargo build --release --target aarch64-apple-darwin | ||
| 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-action@stable | ||
| - name: Cache cargo | ||
| uses: Swatinem/rust-cache@v2 | ||
| - name: Build | ||
| run: cargo build --release | ||
| - name: Check binary size | ||
| run: | | ||
| ls -lh target/release/airml | ||
| echo "Binary size: $(du -h target/release/airml | cut -f1)" | ||