-
Notifications
You must be signed in to change notification settings - Fork 764
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
Maven Toolchains Support #276
Comments
Hello @Okeanos. Thank you for your report. We'll investigate this feature request. |
Related to #245 |
tools.deps would be a great one to support to, specially for Clojure based projects |
To set context, I'm not very familiar with Maven. That said, would it be possible today to handle Maven configuration in a separate step or action? If not, is there some sort of output we can add to |
That depends a little – the To generate a useful and valid toolchains declaration for a particular JDK the following information is necessary:
Optionally, some additional useful information needs to be made available – in particular important for
The |
|
There probably isn't anything missing from a quick glance – that is a fair point and something I overlooked initially. Thanks for providing this insight. However, the idea is to reduce friction in the overall Java ecosystem on GitHub Runners. I dare say a huge number of people who works with a JVM based language in Github Actions uses This addition makes it very easy for the people to correctly consume JDKs (even matrix builds) by getting a minimal discovery setup out of the way "batteries included"-style. Where's the friction imposed by an additional step? Such a step has to be separately maintained. The maintainers will have to carefully watch changes to |
I see thanks for the explanation and for suggesting the feature. I'm happy to leave this issue open to see if it attracts more attention, but wanted to make sure you weren't blocked. |
I can only second @Okeanos this would be a very useful feature, currently we have to manually setup this stuff and maintain |
A very welcomed feature! |
@brcrista any progress here? We have:
so what is holding this back? |
Mostly just our bandwidth. Expanding the scope of the action / feature requests are going to take more thought than a bugfix because of the maintenance implications. Left a comment on the PR. |
I'm sure there will always be people helping out in that area once there is a support for toolchains, as this is very very common in maven setups and cumbersume to setup, just one example how this might currently be done in GH actions: https://blog.bmarwell.de/2020/12/01/testing-maven-with-toolchain-and-github-actions.html Now when you use more than one JDK it even becomes more complex, but actually toochains are exactly for using multiple JDKs (e.g. for multirelease jars) so this would really be a big benefit to have it supported directly by the action! |
Add Maven Toolchains Declaration (#276)
* Add (optional) Maven Toolchains Declaration after JDK is installed * Extract common/shared Maven constants Resolves actions#276
Description:
This is related to #44, however, while that issue in particular asks for multiple JDKs to be installed with a single
setup-java
invocation, I would like the generalsetup-java
invocation to provide a Maven Toolchains declaration for the selected JDK(s).This requires putting a
toolchains.xml
file with the proper definitions into the$HOME/.m2
location of the current user, i.e. the one running Maven.Implementation of #44 would require changes to this, i.e. all additional JDKs would have to be correctly exposed in the toolchains declaration as well.
Justification:
This would allow using
setup-java
with less overhead in projects that have Maven toolchain requirements configured and also allow Gradle to pick up JDK locations automatically starting with 7.4. This was something discussed in #44 as well and is to be implemented in gradle/gradle#14903 with a different solution.Are you willing to submit a PR?
There's a pull request: #282
The text was updated successfully, but these errors were encountered: