mill icon indicating copy to clipboard operation
mill copied to clipboard

Inconsistent environment variable handling, `JAVA_HOME` is ignored

Open lefou opened this issue 1 month ago • 0 comments

Mill is handling environment variables inconsistently.

Most env vars have a higher priority that file-based configurations. E.g. We allow to change the Mill version with MILL_VERSION, even when there is a .mill-version file present.

But a JAVA_HOME variable is ignored, when .mill-jvm-version is present and set. IMHO, we should only use .mill-jvm-version, when there is no explicit JAVA_HOME. E.g. when the user has a java executable on the path but no JAVA_HOME env var defined, Mill should use the config from .mill-jvm-version.

lefou avatar Oct 26 '25 13:10 lefou