lang-lib 1.0.0

A lightweight, high-performance localization library for Rust. Loads TOML language files, supports runtime locale switching, configurable paths, and automatic fallback chains.
Documentation
name: Benchmarks

on:
  workflow_dispatch:
  push:
    branches:
      - main
    paths:
      - Cargo.toml
      - Cargo.lock
      - benches/**
      - src/**
      - examples/**

jobs:
  benchmark:
    name: Criterion Benchmarks
    runs-on: ubuntu-latest

    steps:
      - name: Check out repository
        uses: actions/checkout@v4

      - name: Install Rust toolchain
        uses: dtolnay/rust-toolchain@stable

      - name: Cache Rust artifacts
        uses: Swatinem/rust-cache@v2

      - name: Run Criterion benchmarks
        run: cargo bench --bench performance

      - name: Upload Criterion reports
        uses: actions/upload-artifact@v4
        with:
          name: criterion-report
          path: target/criterion
          if-no-files-found: error

      - name: Write workflow summary
        run: |

          echo "## Benchmark Run" >> $GITHUB_STEP_SUMMARY
          echo "Criterion reports were uploaded as the \\`criterion-report\\` artifact." >> $GITHUB_STEP_SUMMARY
          echo "See BENCHMARKS.md for guidance on interpreting regressions." >> $GITHUB_STEP_SUMMARY