ndaxrs 0.1.0

Rust client library for the NDAX cryptocurrency exchange API
Documentation
name: Check ✅

on:
  workflow_dispatch:
  push:
    paths:
      - "**"
      - "!**.md"
  pull_request:
    paths:
      - "**"
      - "!**.md"

env:
  CARGO_TERM_COLOR: always
  RUST_BACKTRACE: full

jobs:
  check:
    name: Check Rust
    runs-on: ubuntu-latest
    env:
      RUSTFLAGS: --deny warnings

    steps:
      - name: Checkout 🛒
        uses: actions/checkout@v6

      - name: Setup Rust toolchain 🦀
        uses: dtolnay/rust-toolchain@nightly
        with:
          components: rustfmt, clippy

      - name: Show cargo version
        run: cargo --version

      - name: Rust build caching
        uses: Swatinem/rust-cache@v2
        with:
          key: check
          workspaces: . -> target
          save-if: ${{ github.ref == 'refs/heads/main' }}

      - name: Check ✅
        run: cargo check --verbose

  lint-rust:
    name: Lint Rust
    runs-on: ubuntu-latest

    steps:
      - name: Checkout 🛒
        uses: actions/checkout@v6

      - name: Setup Rust toolchain 🦀
        uses: dtolnay/rust-toolchain@nightly
        with:
          components: rustfmt, clippy

      - name: Show cargo version
        run: cargo --version

      - name: Rust build caching
        uses: Swatinem/rust-cache@v2
        with:
          key: lint
          workspaces: . -> target
          save-if: ${{ github.ref == 'refs/heads/main' }}

      - name: Format
        run: cargo fmt -- --check

      - name: Clippy
        run: cargo clippy --all-targets --all-features -- -D warnings