---
name: CI

# yamllint disable-line rule:truthy
on:
  push:
    branches: [master]

  pull_request:

permissions:
  contents: read

concurrency:
  # yamllint disable-line rule:line-length
  group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
  cancel-in-progress: true

jobs:
  build:
    runs-on: ubuntu-latest

    steps:
      - uses: actions/checkout@v4
      - uses: actions/setup-python@v5
        with:
          python-version: "3.12"
          cache: "pip"
      - name: Install opuslib
        run: sudo apt-get install -y libopus0
      - run: script/setup --dev
      - run: script/lint
      - run: script/test
