Skip to content
Permalink
Browse files

Fix JENKINS-13566

  • Loading branch information...
gboissinot committed Apr 24, 2012
1 parent add1dc3 commit 9f43a3a2ee2312c763c73e10281f4b1fc34f9106
Showing with 7 additions and 2 deletions.
  1. +7 −2 src/main/java/org/jenkinsci/plugins/envinject/service/EnvInjectEnvVars.java
@@ -9,6 +9,7 @@
import org.jenkinsci.lib.envinject.EnvInjectException;
import org.jenkinsci.lib.envinject.EnvInjectLogger;

import java.io.File;
import java.io.IOException;
import java.io.Serializable;
import java.util.HashMap;
@@ -157,7 +158,7 @@ public int executeScript(
variables.putAll(contribEnvVars);
variables.putAll(propertiesEnvVars);

//4-- Remove unset variables and return the resullt
//4-- Remove unset variables
return removeUnsetVars(variables);
}

@@ -207,7 +208,11 @@ private boolean isUnresolvedVar(String value) {
}

private String removeEscapeDollar(String value) {
return value.replace("\\$", "$");
//We replace escaped $ unless we are on Windows (Unix only)
if ('/' == File.separatorChar) { //unix test
return value.replace("\\$", "$");
}
return value;
}

}

0 comments on commit 9f43a3a

Please sign in to comment.
You can’t perform that action at this time.