提交 3eea3964 编写于 作者: V Vojtech Juranek

[FIXED JENKINS-19488] Expand variable in a consistent way

上级 7e131ec2
......@@ -1087,6 +1087,9 @@ public abstract class Launcher {
*/
private static EnvVars inherit(Map<String,String> overrides) {
EnvVars m = new EnvVars(EnvVars.masterEnvVars);
// first add all values and then eventually expand them as values can refer other newly added values (see JENKINS-19488)
for (Map.Entry<String,String> o : overrides.entrySet())
m.override(o.getKey(),o.getValue());
for (Map.Entry<String,String> o : overrides.entrySet())
m.override(o.getKey(),m.expand(o.getValue()));
return m;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册