Skip to content

Allow to add a toolchain only - without updating settings.xml, JAVA_HOME and PATH. Only toolchains.xml must be extended. #552

Open
@mhoffrog

Description

Description:
Allow to add another toolchain only by a subsequent setup-java - only toolchains.xml must be updated with the additional JDK setup and the JDK specific JAVA_HOME_<jdk version> must be set.
No update of settings.xml, no add to PATH, no update of JAVA_HOME.

Justification:
In my scenario I run a first setup-java configuring settings.xml and setting up my JAVA_HOME JDK.
Then I determine a probable additionally required toolchain version from the compile target setting of my Maven projects POM.
If this is requiring a different JDK, then I am running another setup-java for this toolchain.
In this case I want to get the toolchains.xml being extended only and to preserve JAVA_HOME, PATH and settings.xml from my first setup-java.
Currently I am working around this requirement by a step preserving JAVA_HOME, PATH and settings.xml before the setup-java step and restoring those after that step. This is working fine so far.
Another config property for setup-java like e.g. add-toolchain-only would save those efforts!

Are you willing to submit a PR?
Yes - cannot promise a timeline yet.

Metadata

Assignees

No one assigned

    Labels

    feature requestNew feature or request to improve the current logicneeds eyes

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions