refreshVersions
refreshVersions copied to clipboard
Migration for Kotlin/JS dependencies
- [x] I have read the guidelines for submitting issues
⚠️ Is your feature request related to a problem? Please describe
After running ./gradlew refreshVersionsMigrate, a typical Kotlin/JS project might look like this:
dependencies {
testImplementation(kotlin("test-js"))
implementation(project(":client"))
// Simplified by refreshVersions
implementation(KotlinX.coroutines.coreJs)
// Omitted version thanks to refreshVersions
implementation("org.jetbrains.kotlin-wrappers:kotlin-react:_")
implementation("org.jetbrains.kotlin-wrappers:kotlin-react-dom:_")
// refreshVersions is currently unable to manage NPM dependencies
implementation(npm("react", "17.0.2"))
implementation(npm("react-dom", "17.0.2"))
}
💡 Describe the solution you'd like
From the comments in https://github.com/jmfayard/refreshVersions/issues/457, it seems like refreshVersions already supports the _ notation for NPM dependencies. However, the refreshVersionsMigrate isn't able to implement it itself.
🤚 Do you want to develop this feature yourself?
- [ ] Yes
- [x] No
I currently have very little time and have never written Gradle plugins previously, however if it's a few simple changes I can find some time to do it. I don't have the knowledge for anything more involved, though.
Hello, if you want, we can look at this together in a pair-programming session so you'll get to understand how refreshVersions works, at least for the automatic migration system.
Hi, I'd be interested by that, but sadly I won't have the time for it until February at the soonest.
Hello @CLOVIS-AI
Good news is that it's a valid issue so anyone is free to work on that.
On the other hand, realistically we won't have the time and energy to work on this rather than other things. I prefer to be honest about it and close the issue.
As an added note if anyone else needs this, if you write implementation(npm("whatever", "_")), then run refreshVersions (not refreshVersionsMigrate), it will automatically fill in the latest version in versions.properties with the correct syntax.
It's not really a fix for this feature, but my issue really was finding out what the syntax was so it's a good workaround for me in the meantime.