-
-
Notifications
You must be signed in to change notification settings - Fork 384
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add a MillBuildModule
and improve BSP for build.sc
#1972
Conversation
New release of using_directives is out. https://github.com/VirtusLab/using_directives/releases/tag/v0.0.9 |
3a04e86
to
628117c
Compare
MillBUildModule
and improve BSP for build.sc
MillBuildModule
and improve BSP for build.sc
2dbe780
to
1a12a56
Compare
a5ce916
to
a605a47
Compare
a2b2813
to
11259e1
Compare
# Conflicts: # build.sc # Conflicts: # build.sc
Using directives parser is currently not able to handle larger files, see VirtusLab/using_directives#41 Also improved BSP support. BSP mill-build modules should now be able to compile build files. # Conflicts: # scalalib/src/mill/scalalib/bsp/BspModule.scala
But use wrapped files in compilatin and semanticDb generation. Still need to figure out, how to properly match those to the original files.
1d97b0e
to
543d158
Compare
@lefou my team is quite affected by Metals not working in build.sc (we're forced to use intellij, which has its well-known issues). Is there something I/we can do to help get this over the line? |
This PR is currently not suitable for merging. I think I made some mistake in the latest rebase, so it fails most CI jobs. Also, the wrapping of the *.sc isn't correct. I currently use IntelliJ via |
if you're asking about IDEA itself...
|
I tried that (after a somewhat confusing process of getting the locally published version work in the launcher), but it didn't seem to have much of an effect on our build :/ |
Oh, sorry to hear that. If I cut a |
Yes, a release would help (I had issues getting millw to work with snapshots) :) I will then try to minimize the things that make it not work. |
We already have a released version |
okay, tried that and it still didn't work - posted a minimal reproduction in #2304. |
BSP support is already improved by This PR needs more work, including a rebase, so I'm closing it for now. |
The idea is to have a Module that can read and build Mill projects.
With such a module, we can model the build files compilation with Mill instead of Ammonite.
This also opens the door for further improvements. Incremental compilation and better BSP support comes to mind.
I experimentally also included support for
using directives
as comments, as they are used in Scala CLI. This is to play with it, but also to eventually replace the Ammonite-specific import syntax.Tasks:
Caveats:
using
directives.Try it out
Additional to the
trait
, I also created an external modulemill.scalalib.buildfile.MillBuildModule
, so you can easily test it with any project you want.