cache-mod 1.0.0

High-performance in-process caching with multiple eviction policies (LRU, LFU, TinyLFU, TTL, size-bounded). Async-safe, lock-minimized internals. Typed key-value API. No dependency on any external store.
Documentation
name: CI

on:
  push:
    branches: [main, dev]
  pull_request:
    branches: [main, dev]

env:
  CARGO_TERM_COLOR: always
  RUSTFLAGS: "-D warnings"
  FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true

jobs:
  check:
    name: Check
    runs-on: ${{ matrix.os }}
    strategy:
      fail-fast: false
      matrix:
        os: [ubuntu-latest, macos-latest, windows-latest]
        rust: [stable, "1.75.0"]
    steps:
      - uses: actions/checkout@v5
      - uses: dtolnay/rust-toolchain@master
        with:
          toolchain: ${{ matrix.rust }}
          components: clippy, rustfmt
      - name: Cache
        uses: Swatinem/rust-cache@v2
        with:
          key: ${{ matrix.os }}-${{ matrix.rust }}

      # MSRV row: verify the library alone compiles on the declared MSRV.
      # Dev-dependencies (criterion, proptest) are intentionally not loaded —
      # they are free to have higher MSRVs without violating the library's
      # MSRV promise. This is the same pattern config-lib uses.
      - name: MSRV check (library only)
        if: matrix.rust == '1.75.0'
        run: cargo check --lib --all-features

      # Stable row: full fmt / clippy / test / doc sweep including dev-deps,
      # integration tests, doctests, property tests, and benches.
      - name: fmt
        if: matrix.rust == 'stable'
        run: cargo fmt --all -- --check
      - name: clippy (all features)
        if: matrix.rust == 'stable'
        run: cargo clippy --all-targets --all-features -- -D warnings
      - name: clippy (no default features)
        if: matrix.rust == 'stable'
        run: cargo clippy --all-targets --no-default-features -- -D warnings
      - name: test
        if: matrix.rust == 'stable'
        run: cargo test --all-features
      - name: doc
        if: matrix.rust == 'stable'
        run: cargo doc --no-deps --all-features
        env:
          RUSTDOCFLAGS: "-D warnings"