# https://docs.github.com/en/code-security/dependabot/dependabot-version-updates/optimizing-pr-creation-version-updates#setting-up-a-cooldown-period-for-dependency-updates

version: 2
updates:
  - package-ecosystem: cargo
    directories:
      - tests
      - tests/wasm-workspace
    schedule:
      interval: weekly
    # https://docs.github.com/en/code-security/dependabot/working-with-dependabot/dependabot-options-reference#groups--
    # 1 PR per week and group
    groups:
      cargo-major:
        update-types: ["major"]
      cargo-minor:
        update-types: ["minor"]
      cargo-patch:
        update-types: ["patch"]
  - package-ecosystem: github-actions
    directory: /
    schedule:
      interval: weekly
    groups:
      actions:
        # Combine all images of the last week
        patterns: ["*"]
  - package-ecosystem: npm
    directory: /
    schedule:
      interval: weekly
    groups:
      prd-major:
        dependency-type: "production"
        update-types: ["major"]
      prd-minor:
        dependency-type: "production"
        update-types: ["minor"]
      prd-patch:
        dependency-type: "production"
        update-types: ["patch"]
      dev-major:
        dependency-type: "development"
        update-types: ["major"]
      dev-minor:
        dependency-type: "development"
        update-types: ["minor"]
      dev-patch:
        dependency-type: "development"
        update-types: ["patch"]
