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

Support for changing Gradle dependency versions in TOML files #4400

Open
michaelmcfadyensky opened this issue Aug 8, 2024 · 2 comments
Open
Labels
enhancement New feature or request parser-gradle parser-toml recipe Requested Recipe

Comments

@michaelmcfadyensky
Copy link

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

@michaelmcfadyensky michaelmcfadyensky added the enhancement New feature or request label Aug 8, 2024
@timtebeek
Copy link
Contributor

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

@timtebeek timtebeek changed the title Support for changing versions in TOML files Support for changing Gradle dependency versions in TOML files Aug 8, 2024
@timtebeek
Copy link
Contributor

@steplica thanks a lot for the offer to help!

  1. I think in the early stages of getting the parser to work @knutwannheden might be best to guide you, as he's been most active with recent parser developments. I'd expect rewrite-toml should still be part of openrewrite/rewrite, with an eye towards integration with Gradle
  2. once the parser works we'd need to hook it into the rewrite-maven-plugin and rewrite-gradle-plugin, and rewrite-polyglot
  3. then once files are parsed as Toml, we'd need to integrate with our Gradle support; at that point we can tag Shannon Pamperl (also here) for guidance, likely looking towards our Trait support to minimize recipe changes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request parser-gradle parser-toml recipe Requested Recipe
Projects
Status: Backlog
Development

No branches or pull requests

2 participants