unbundle 5.2.0

Unbundle media files - extract still frames, audio tracks, and subtitles from video files
Documentation
name: CI

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

jobs:
  test-default:
    name: Test (default) - ${{ matrix.os }}
    runs-on: ${{ matrix.os }}
    strategy:
      fail-fast: false
      matrix:
        os: [ubuntu-latest, macos-latest, windows-latest]

    steps:
      - name: Checkout
        uses: actions/checkout@v4

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

      - name: Install FFmpeg deps (Ubuntu)
        if: runner.os == 'Linux'
        run: |
          sudo apt-get update
          sudo apt-get install -y \
            pkg-config \
            libavcodec-dev \
            libavformat-dev \
            libavutil-dev \
            libswscale-dev \
            libswresample-dev \
            libavdevice-dev

      - name: Install FFmpeg deps (macOS)
        if: runner.os == 'macOS'
        run: |
          brew update
          brew install ffmpeg pkg-config

      - name: Install FFmpeg deps (Windows + vcpkg)
        if: runner.os == 'Windows'
        shell: pwsh
        run: |
          git clone https://github.com/microsoft/vcpkg.git vcpkg
          .\vcpkg\bootstrap-vcpkg.bat
          .\vcpkg\vcpkg.exe install ffmpeg:x64-windows

      - name: Configure FFmpeg runtime PATH (Windows)
        if: runner.os == 'Windows'
        shell: pwsh
        run: |
          $ffmpegBin = Join-Path $env:GITHUB_WORKSPACE "vcpkg\installed\x64-windows\bin"
          $ffmpegTools = Join-Path $env:GITHUB_WORKSPACE "vcpkg\installed\x64-windows\tools\ffmpeg"

          if (!(Test-Path $ffmpegBin)) {
            throw "Expected FFmpeg DLL directory not found: $ffmpegBin"
          }

          $ffmpegBin | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append

          if (Test-Path $ffmpegTools) {
            $ffmpegTools | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
          }

      - name: Rustfmt check
        if: runner.os == 'Linux'
        run: cargo fmt --all -- --check

      - name: Build (Linux/macOS)
        if: runner.os != 'Windows'
        run: cargo build

      - name: Build (Windows)
        if: runner.os == 'Windows'
        env:
          VCPKG_ROOT: ${{ github.workspace }}/vcpkg
          VCPKGRS_DYNAMIC: "1"
          FFMPEG_DIR: ${{ github.workspace }}/vcpkg/installed/x64-windows
        run: cargo build

      - name: Test (Linux/macOS)
        if: runner.os != 'Windows'
        run: cargo test

      - name: Test (Windows)
        if: runner.os == 'Windows'
        env:
          VCPKG_ROOT: ${{ github.workspace }}/vcpkg
          VCPKGRS_DYNAMIC: "1"
          FFMPEG_DIR: ${{ github.workspace }}/vcpkg/installed/x64-windows
        run: cargo test

  test-all-features:
    name: Test (all features)
    runs-on: ubuntu-latest

    steps:
      - name: Checkout
        uses: actions/checkout@v4

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

      - name: Install FFmpeg deps
        run: |
          sudo apt-get update
          sudo apt-get install -y \
            pkg-config \
            libavcodec-dev \
            libavformat-dev \
            libavutil-dev \
            libswscale-dev \
            libswresample-dev \
            libavdevice-dev

      - name: Build all features
        run: cargo build --all-features

      - name: Test all features
        run: cargo test --all-features