rtformat 0.1.4

A library for runtime formatting in Rust
Documentation
name: CI

on:
  push:
    branches: [main]
  pull_request:

concurrency:
  group: ${{ github.workflow }}-${{ github.ref }}
  cancel-in-progress: true

env:
  CARGO_TERM_COLOR: always

jobs:
  test:
    name: Test (${{ matrix.os }}, ${{ matrix.toolchain }})
    runs-on: ${{ matrix.os }}
    strategy:
      fail-fast: false
      matrix:
        os: [ubuntu-latest, windows-latest, macos-latest]
        toolchain: ["1.88", stable, beta]
    steps:
      - uses: actions/checkout@v4
      - uses: dtolnay/rust-toolchain@master
        with:
          toolchain: ${{ matrix.toolchain }}
      - name: Run tests (unit + doc)
        run: cargo test --workspace

  no-std:
    name: Build (thumbv6m-none-eabi, no_std)
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - uses: dtolnay/rust-toolchain@stable
        with:
          targets: thumbv6m-none-eabi
      - name: Build for a bare-metal target (proves no_std + alloc)
        run: cargo build -p rtformat --target thumbv6m-none-eabi

  lints:
    name: Clippy + rustfmt
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - uses: dtolnay/rust-toolchain@stable
        with:
          components: clippy, rustfmt
      - name: rustfmt
        run: cargo fmt --all --check
      - name: Clippy
        run: cargo clippy --all-targets --workspace -- -D warnings

  semver:
    name: SemVer check
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - name: Check for breaking changes against the last release
        uses: obi1kenobi/cargo-semver-checks-action@v2