# Dependabot configuration for automatic dependency updates
# Generated by pypreset augment
# https://docs.github.com/en/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file

version: 2
updates:
{% if package_manager == "poetry" %}
  # Python dependencies (Poetry/pip)
  - package-ecosystem: "pip"
    directory: "/"
    schedule:
      interval: "{{ dependabot.schedule }}"
    open-pull-requests-limit: {{ dependabot.open_pull_requests_limit }}
    commit-message:
      prefix: "deps"
    labels:
      - "dependencies"
      - "python"
    groups:
      python-packages:
        patterns:
          - "*"
        exclude-patterns:
          - "pytest*"
          - "ruff"
          - "mypy"
          - "black"
      python-dev:
        patterns:
          - "pytest*"
          - "ruff"
          - "mypy"
          - "black"
{% elif package_manager == "pdm" %}
  # Python dependencies (PDM)
  - package-ecosystem: "pip"
    directory: "/"
    schedule:
      interval: "{{ dependabot.schedule }}"
    open-pull-requests-limit: {{ dependabot.open_pull_requests_limit }}
    commit-message:
      prefix: "deps"
    labels:
      - "dependencies"
      - "python"
{% else %}
  # Python dependencies (pip)
  - package-ecosystem: "pip"
    directory: "/"
    schedule:
      interval: "{{ dependabot.schedule }}"
    open-pull-requests-limit: {{ dependabot.open_pull_requests_limit }}
    commit-message:
      prefix: "deps"
    labels:
      - "dependencies"
      - "python"
{% endif %}

  # GitHub Actions
  - package-ecosystem: "github-actions"
    directory: "/"
    schedule:
      interval: "{{ dependabot.schedule }}"
    open-pull-requests-limit: {{ dependabot.open_pull_requests_limit }}
    commit-message:
      prefix: "ci"
    labels:
      - "dependencies"
      - "github-actions"
    groups:
      github-actions:
        patterns:
          - "*"
