Skip to content

Defining Mill builds in pure Scala? #1368

Answered by lefou
itegebo asked this question in Q&A
Discussion options

You must be logged in to vote

Who is supposed to compile your pure Scala file and feed the right classpath to the compiler? That is what you get when using ammonite / mill scripts.
Once you have your file compiled it might be pretty easy to load it in either some stub build.sc or via an external plugin.

Without any knowledge about your external dependency resolution process, you could adapt/override CoursierModule to use your external system.

In essence, when you look at external mill plugins (e.g. https://github.com/lefou/mill-vcs-version), you see what is needed to provide and builds your build definitions outside of mill. All you need in the build.sc is to load the resulting jar.

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by itegebo
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants