You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently, setup-java requires distribution field. However, one can specify a distribution in .java-version thus the distribution input field can be redundant or even confusing when these two disagree.
It'd be great if distribution field is optional and can be configured via .java-version file.
Related work landed in PR #975: it makes distribution optional when java-version-file points to a .sdkmanrc that already carries the SDKMAN distribution suffix, for example java=21.0.5-tem.
Tracked under the epic #1048 (infer Java version/distribution from project files), which groups the related file-based detection requests for consistent design. This issue stays open as the specific sub-request.
TO my knowledge, .java-version from jEnv does not take distribution. And it is unclear if asdf supports as well. Support for SDKMAN was added recently.
Activity
v-priya-kinthali commentedon Jul 18, 2024
Hello @tsawada 👋,
Thank you for this feature request. We will investigate it and get back to you as soon as we have some feedback.
skateball commentedon Feb 11, 2025
Hi @tsawada ,
have you checked to not use a distribution in the yml file?
To me the following should work and use a recent temurin 21 release
Regards Christian
lukaszgyg commentedon Mar 24, 2026
Related work landed in PR #975: it makes
distributionoptional whenjava-version-filepoints to a.sdkmanrcthat already carries the SDKMAN distribution suffix, for examplejava=21.0.5-tem.brunoborges commentedon Jun 23, 2026
Tracked under the epic #1048 (infer Java version/distribution from project files), which groups the related file-based detection requests for consistent design. This issue stays open as the specific sub-request.
brunoborges commentedon Jul 7, 2026
TO my knowledge,
.java-versionfrom jEnv does not take distribution. And it is unclear if asdf supports as well. Support for SDKMAN was added recently.