File (@Nullable Project project) { String path = System.getenv(GRADLE_ENV_PROPERTY_NAME); if (path == null) { return null; } File candidate = new File(path); return isGradleSdkHome(project, candidate) ? candidate : null; }