-
What is the recommended way to have different versions of a particular dependency in the meta build?
now I also need I was trying to define this in a separate package in the
so that each of the respective A bit tangential, but it also seems to not be possible to shared code down to the mill-build. For example, mill-build can't access the One thing I could think of is forgoing the mill-build thing entirely, and doing some hacky thing like this def compileMvnDeps = Seq(mvn"org.openapitools:openapi-generator:6.6.0")
def getCodegen = Task {defaultResolver().classpath(compileMvnDeps()).head} and then use Basically, I want to be able to write locally defined plugins, which can have their own set of independent dependencies, that I can use in my main project without having to publish those separately. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
@arminsumo typically for such scenarios, we use classloaders or JVM subprocesses to isolate the conflicting classpaths. See the docs below for examples: You can also look for examples of this in the Mill codebase, e.g. https://github.com/com-lihaoyi/mill/blob/main/libs/javalib/classgraph-worker/src/mill/javalib/classgraph/impl/ClassgraphWorkerImpl.scala |
Beta Was this translation helpful? Give feedback.
@arminsumo typically for such scenarios, we use classloaders or JVM subprocesses to isolate the conflicting classpaths. See the docs below for examples:
You can also look for examples of this in the Mill codebase, e.g. https://github.com/com-lihaoyi/mill/blob/main/libs/javalib/classgraph-worker/src/mill/javalib/classgraph/impl/ClassgraphWorkerImpl.scala