-
Notifications
You must be signed in to change notification settings - Fork 359
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
Support for changing Gradle dependency versions in TOML files #4400
Comments
Thanks for logging it as an issue! As indicated we do have a toml parser, but that'd need to be dusted off and cleaned up a bit before putting that to use. Likely to tie in with the recently added |
@steplica thanks a lot for the offer to help!
|
will this also support gradle version catalogs defined in |
👍 sounds good. I will keep an eye on this issue. |
|
Next steps:
[1] dependencies {
implementation(libs.guava)
} gradle/libs.versions.toml [libraries]
guava = "com.google.guava:guava:29.0-jre" [2] dependencies {
implementation(libs.guava)
} gradle/libs.versions.toml [libraries]
guava = { group = "com.google.guava", name = "guava", version = "29.0-jre" } [3] dependencies {
implementation(libs.guava)
} gradle/libs.versions.toml [versions]
guava = "29.0-jre"
[libraries]
guava = { group = "com.google.guava", name = "guava", version.ref = "guava" } [4] plugins {
alias(libs.plugins.openrewrite)
} gradle/libs.versions.toml [plugins]
openrewrite = "org.openrewrite.rewrite:5.40.0" [5] plugins {
alias(libs.plugins.openrewrite)
} gradle/libs.versions.toml [plugins]
openrewrite = { id = "org.openrewrite.rewrite", version = "5.40.0" } [6] plugins {
alias(libs.plugins.openrewrite)
} gradle/libs.versions.toml [versions]
openrewrite = "5.40.0"
[plugins]
openrewrite = { id = "org.openrewrite.rewrite", version.ref = "openrewrite" } Additional notes:With both of these recipes, versions found in Links: |
@tompson, I went ahead and broke out your request to a separate issue as it'll be a little bit different than updating the TOML files themselves. |
What problem are you trying to solve?
We specify all of our dependencies and their versions inside toml files for our gradle projects. We would like a away to automate the upgrading of these versions via open rewrite.
Describe the solution you'd like
Recipe available for changing the version of a dependency specified in a toml file
Have you considered any alternatives or workarounds?
Consider using the find and replace recipe but it leads to several work arounds having to be in place for it to work.
Additional context
https://rewriteoss.slack.com/archives/C01A843MWG5/p1723123348552829
The text was updated successfully, but these errors were encountered: