Hi, folks! Quick question: I know about ```aProvid...
# community-support
j
Hi, folks! Quick question: I know about
Copy code
aProvider.zip(bProvider) { a, b -> MyData(a, b) } // Provider<MyData>
but this is fine for merging two providers. What about when I have more of them? Would this be acceptable from the design perspective?
Copy code
providerFactory.provider {
    MyData(a.get(), b.get(), c.get(), d.get())
}
👏 1
v
Well, one of the problems is that you loose implicit task dependencies that way.
github.com/gradle/gradle/issues/32136 requests exactly that (zip for more than 2) and shows how you could do it today with an example with 6 providers.
👏 1
j
Got it, thank you!!
👌 1
v
You should be able to extend my example there for any amount of providers, it just is not really shiny 😄
j
I'm good with not-that-shiny code. 😇
👌 2