mirror of
https://github.com/apache/maven-mvnd.git
synced 2025-09-28 17:15:55 +00:00
Simplify the InterpolationHelper, use 'env.' to align with maven #676
This commit is contained in:
@@ -454,8 +454,10 @@ public class DaemonParameters {
|
||||
if (Files.exists(path)) {
|
||||
try (InputStream in = Files.newInputStream(path)) {
|
||||
result.load(in);
|
||||
InterpolationHelper.performSubstitution((Map<String, String>) (Map) result,
|
||||
new InterpolationHelper.SystemPropertiesSubstitutionCallback());
|
||||
Properties sysProps = new Properties();
|
||||
sysProps.putAll(System.getProperties());
|
||||
System.getenv().forEach((k, v) -> sysProps.put(k, ENV_PREFIX + v));
|
||||
InterpolationHelper.performSubstitution(result, sysProps::getProperty, true, true);
|
||||
} catch (IOException e) {
|
||||
throw new RuntimeException("Could not read " + path);
|
||||
}
|
||||
|
Reference in New Issue
Block a user