queue_rules:
  - name: default
    conditions:
      # Conditions to get out of the queue (= merged)
      - status-success=Run Unit Tests

pull_request_rules:
  - name: Automatically merge on CI success and review approval
    conditions:
      - base~=main|integ-tests
      - "#approved-reviews-by>=1"
      - -approved-reviews-by~=author
      - status-success=Run Unit Tests
      - label!=work-in-progress
      - -title~=(WIP|wip)
      - -merged
      - -closed
      - author!=dependabot[bot]
    actions:
      queue:
        method: squash
        name: default

  - name: Automatically approve and merge Dependabot PRs
    conditions:
      - base~=main
      - author=dependabot[bot]
      - status-success=Run Unit Tests
      - -title~=(WIP|wip)
      - -label~=(blocked|do-not-merge)
      - -merged
      - -closed
    actions:
      review:
        type: APPROVE
      queue:
        method: squash
        name: default
