aoss-curl 1.0.25

Request to Amazon OpenSearch Service with SigV4 🔏
Documentation
name: CI

on:
  pull_request:
    branches:
      - main
  push:
    branches:
      - main

jobs:
  check:
    name: Check
    runs-on: ubuntu-latest
    steps:
      - name: Checkout repository
        uses: actions/checkout@v6

      - name: Setup rust
        uses: dtolnay/rust-toolchain@stable
        with:
          components: rustfmt, clippy

      - name: Run cargo fmt
        run: cargo fmt --all --check

      - name: Run cargo check
        run: cargo check

      - name: Run cargo clippy
        run: cargo clippy -- -D warnings

      - name: Run cargo test
        run: cargo test

  build:
    name: Build
    needs: check
    strategy:
      matrix:
        include:
          - target: x86_64-unknown-linux-gnu
            os: ubuntu-latest
            command: cargo

          - target: aarch64-unknown-linux-gnu
            os: ubuntu-latest
            command: cross

          - target: x86_64-apple-darwin
            os: macos-latest
            command: cargo

          - target: aarch64-apple-darwin
            os: macos-latest
            command: cargo

    runs-on: ${{ matrix.os }}
    steps:
      - name: Checkout repository
        uses: actions/checkout@v6

      - name: Setup rust
        uses: dtolnay/rust-toolchain@stable
        with:
          target: ${{ matrix.target }}

      - name: Install cross
        run: cargo install cross
        if: matrix.command == 'cross'

      - name: Run ${{ matrix.command }} build
        run: ${{ matrix.command }} build --release --locked --target ${{ matrix.target }}