This message was deleted.
# dependency-management
s
This message was deleted.
c
Hmm… does an
ArtifactView
with a suitable component filter achieve this?
t
I just discovered component filter! checking now
c
it feels like it could… but I’ve never tried it
There is a really evil way of doing it… if that doesn’t work…
t
I think this works
Copy code
it.componentFilter { componentIdentifier ->
  componentIdentifier is ModuleComponentIdentifier
}
c
👍
e
t
interesting. We don't use dependency locking yet (though we should)
c
all you people using dependency locking before you started worrying about `failOnVersionConflict()`… 😛
t
I wanted to get us using platforms consistently first, because we have so many version conflicts across the build
c
I’m kidding… although my experience says this is a huge issue in open source projects… most cases are probably harmless… but people are stupidly slapdash about it.
e
I've started using this (well, a a bit complex in real usage but you get the gist) to define a platform based on the contents of a version catalog. seems to work pretty easily
👍 2
t
that presupposes we're already using version catalogs << (but yes, it's a neat approach) 🔖
b
I happen to be doing exactly this today, trying to pre-populate the dependency cache on a docker image for ephemeral builds. Care to share your final solution? I’m about halfway there, got things resolving for specific configurations, now working on resolving all resolvable configurations…
t
jvm or android or both?
b
jvm
t
eh, here's the whole thing. You can simplify it dramatically by deleting the android-specific stuff https://gist.github.com/autonomousapps/f0133e58a612b6837f3f4f6554337035
note that this only resolves the compileClasspath, not, say, testCompileClasspath
b
Thanks for sharing! That helps immensely.
👍 1