-
Notifications
You must be signed in to change notification settings - Fork 6
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
Read Scala options from pom.xml #27
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for this. Sorry, I completely missed this PR.
I can see why you would want that and I think we have a similar thing for Kotlin in core Quarkus.
I don't think this is the right approach though as we end up having something really tied to Maven in the extension implementation.
The Kotlin part is in two parts:
- Allow setting kotlinc compiler arguments in dev task/mojo quarkusio/quarkus#25346 - I think this could be implemented in this extension too. It's not ideal as you have to copy the args but it's still better than nothing and could be a workaround for now
- there is another part in
DevMojo.setKotlinSpecificFlags(...)
that is hardcoded and is not pluggable and that is actually doing what you want (I think)
So what I would recommend:
- implement the first approach in the extension to have a workaround for now
- and then the second approach would need some additional work in Quarkus core to make it pluggable (and the Kotlin part should be moved to the Kotlin extension too). If you want to pursue this, it's probably a good idea to ask @aloubyansky to ask for advice about the design.
HTH.
Thanks for the comment @gsmet ... I've revisited this and done a couple tests and found the compiler arguments set in Before:
After adding
So I understand the change in this PR and the suggestion you made is not needed. Right? |
This PR adds POM parsing to fetch Scala compiler options defined in the
scala-maven-plugin
configuration.The environment variable still have preference if passed.