Renovate: Combine all updates to one branch/PR
Asked Answered
M

2

18

Renovate is updating the packages as soon as there is a new version. But renovate also creates a seperate PR/branch for each update. So if new versions released for 5 of my packages renovate will create 5 branches. This leads to 5 pipelines, 1 PR is merged and the other 4 will rebase and run the pipeline again. So there will run 15 PR-pipelines + the pipeline for the main branch on each merge.
So all together there will run 19 pipelines.

Is it possible to combine – lets say all minor and patch updates – into one branch and PR to avoid the huge amount of PRs?

the only thing I found was the prConcurrentLimit which avoids the rebase and rerun of the PR-pipelines on each merge. But this will also trigger 10 pipelines.

If I can combine all together there is just 1 PR pipeline and 1 main-branch pipeline. So 2 pipelines in total. That would be awesome.

Marquet answered 4/3, 2021 at 8:29 Comment(0)
T
26

Yes you can group updates together, for all nonmajor updates this can look like this: (taken from the renovate docs)

{
  "packageRules": [
    {
      "matchPackagePatterns": [
        "*"
      ],
      "matchUpdateTypes": [
        "minor",
        "patch"
      ],
      "groupName": "all non-major dependencies",
      "groupSlug": "all-minor-patch"
    }
  ]
}
Towards answered 13/4, 2021 at 8:44 Comment(0)
C
3

You can use the preset group:allNonMajor, which does out of the box exactly what is written in another answer to this question. You can use the preset by adding it to the extends array of your renovate config:

{                                                                                                                                                                                                             
    "extends": ["group:allNonMajor"]
}
Cufic answered 4/4 at 21:59 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.