Plugin to ease Cross Platform projects #2081
lolgab
started this conversation in
Show and tell
Replies: 1 comment 2 replies
-
This is great. One question, just to be sure, I could use it for only some platforms, right? Like just JVM and JS and not native, for instance. Also, it would be great to see an example that demonstrates a more complicated real world scenario, namely something like the following: graph RL;
Shared2 --> Shared1;
JVM2 --> JVM1;
JVM1 --> Shared2;
JS2 --> JS1;
JS1 --> Shared2;
Shared2 should depend on Shared1 for everything respectively, but JVM1 depends only on Shared2's JVM module and JS1 only depends on its JS module. |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Cross-platform projects are complex in Mill. Much harder than in Sbt.
I've been trying many times to find a way to reduce the amount of boilerplate and duplication needed to publish a library for multiple Scala platforms ( JVM, JS, and Native ).
I came out with this plugin: https://github.com/lolgab/mill-crossplatform
It tries to ease cross-platform projects, but also to support more complex use cases. I tried with
utest
's build and it is capable of building it.What do you think? Do you want to try it out?
Known Drawbacks:
The plugin assumes that all platforms share the same Scala Versions. It can be not what you need in some cases, for example, when Scala Native didn't yet support Scala 3, builds needed to exclude Scala 3 only on the Scala Native projects.
Beta Was this translation helpful? Give feedback.
All reactions