Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace Renovate with Dependabot #3377

Merged
merged 5 commits into from
Mar 8, 2023
Merged

Conversation

chemicL
Copy link
Member

@chemicL chemicL commented Mar 8, 2023

This PR is a continuation of #3232 and supersedes that one.

Soon, hopefully, Dependabot will be able to support version catalogs: dependabot/dependabot-core#6249

That's why the libs.versions.toml file is still kept, despite introducing a bit of duality in the build setup.


Below is @simonbasle's original description:

This PR replaces Renovate with Dependabot.

Despite being less configurable, Dependabot can target a non-default branch.

One limitation is that Dependabot currently doesn't process version catalogs, even in the standard format of gradle/libs.versions.toml.
It should however be able to process version strings imported from a .gradle file as long as the filename contains dependencies` (see source).
So unfortunately this means rolling back version catalogs, at lest partially.

The version declarations broadly go into 4 categories:

  1. Reactor versions that we always edit during the release
  2. Versions that we want to more closely monitor, or freeze
  3. Plugins
  4. Other libraries

While (4) can and should be managed by Dependabot, the first three categories cannot or shouldn't.
In this PR I chose to keep (1/2/3) in the libs.versions.toml version catalog and split out versions from (4) into a new gradle/dependencies.gradle file to be imported.

That file would thus be understood, monitored and updated by Dependabot only, while we continue to make manual edits to gradle/libs.versions.toml (and root gradle.properties).

Drawbacks

The plugins won't be auto-updated anymore and will need manual monitoring and updates.

Alternatives

This is more a question of style but in the current state, we reintroduce the artifact coordinates in each build.gradle (eg. implementation "group:my-artifact:$myArtifactVersion").
I've found one blog post that uses a different style where the whole coordinates are defined inside the dependencies.gradle file in a dictionnary:

// in gradle/dependecies.gradle:
libs = {
myArtifact : "group:my-artifact:$myArtifactVersion"
}

// in individual build.gradle files
dependencies {
implementation libs.myArtifact
}
See blog post.
This could be considered as a further improvement.

simonbasle and others added 5 commits March 7, 2023 16:02
@chemicL chemicL added the type/chores A task not related to code (build, formatting, process, ...) label Mar 8, 2023
@chemicL chemicL requested a review from a team as a code owner March 8, 2023 11:04
@chemicL chemicL self-assigned this Mar 8, 2023
@chemicL
Copy link
Member Author

chemicL commented Mar 8, 2023

It's also worth noting that plugin updates might also be supported soon, as per the recent update here: dependabot/dependabot-core#1164 (comment)

@chemicL chemicL merged commit cd2cc12 into 3.4.x Mar 8, 2023
@reactorbot
Copy link

@chemicL this PR seems to have been merged on a maintenance branch, please ensure the change is merge-forwarded to intermediate maintenance branches and up to main 🙇

chemicL added a commit that referenced this pull request Mar 8, 2023
@chemicL chemicL deleted the replaceRenovateWithDependabot branch March 8, 2023 12:33
@chemicL chemicL added this to the 3.4.28 milestone Mar 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type/chores A task not related to code (build, formatting, process, ...)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants