name: Build
on: [push]
jobs:
  build:
    runs-on: ubuntu-latest
    steps:
    - name: Checkout
      uses: actions/checkout@v4
    - name: Setup OCaml
      uses: ocaml/setup-ocaml@v2
      with:
        ocaml-compiler: 5.00
    - name: Install required packages
      run: sudo apt install ffmpeg
    - name: Pin package
      run: opam pin add -n .
    - name: Install dependencies
      run: opam depext -yt metadata
    - name: Build and install
      run: opam install -t .
    - name: Run tests
      run: eval $(opam env) && dune build @citest
