trallocator 0.2.2

A no_std lbrary for wrapping an existing allocator and tracking the heap usage.
Documentation
name: Run the CI
on:
  push:
    branches: [main]
  pull_request:

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

      - name: Install toolchain
        uses: actions-rs/toolchain@v1
        with:
          toolchain: nightly
          override: true
          components: clippy

      - name: Cargo cache
        uses: Swatinem/rust-cache@v2

      - name: Clippy check
        run: cargo clippy

      - name: Clippy check tests
        run: cargo clippy --tests

  fmt:
    name: Format
    runs-on: ubuntu-latest
    steps:
      - name: Checkout sources
        uses: actions/checkout@v3

      - name: Install toolchain
        uses: actions-rs/toolchain@v1
        with:
          toolchain: nightly
          override: true
          components: rustfmt

      - name: Cargo cache
        uses: Swatinem/rust-cache@v2

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

  Doc:
    runs-on: ubuntu-latest
    steps:
      - name: Checkout sources
        uses: actions/checkout@v3

      - name: Install toolchain
        uses: actions-rs/toolchain@v1
        with:
          toolchain: nightly
          override: true

      - name: Cargo cache
        uses: Swatinem/rust-cache@v2

      - name: Create doc
        run: cargo doc --all-features
        env:
          RUSTDOCFLAGS: --cfg docsrs # mimic docs.rs build

  Tests:
    runs-on: ubuntu-latest
    steps:
      - name: Checkout sources
        uses: actions/checkout@v3

      - name: Install toolchain
        uses: actions-rs/toolchain@v1
        with:
          toolchain: nightly
          override: true

      - name: Cargo cache
        uses: Swatinem/rust-cache@v2

      - name: Run tests
        run: cargo test --all-features

  MSRV:
    runs-on: ubuntu-latest
    steps:
      - name: Checkout sources
        uses: actions/checkout@v3

      - name: Install toolchain
        uses: actions-rs/toolchain@v1
        with:
          toolchain: 1.56.1
          override: true

      # Doesn't try to build all features
      - name: Run check
        run: cargo build --features=max-usage