Details
-
Bug
-
Status: Resolved (View Workflow)
-
Minor
-
Resolution: Fixed
-
None
-
Windows
Description
Under windows, the variable "WORKSPACE" usually contains backward-shlashes (i.e. "C:\Jenkins\foo\bar"). Trying to assign a string variable like
String baz = "$WORKSPACE
sandbox";
is not possible. After the variables are substitued Groovy complains about illegal character, since the statement looks like this:
String baz = "C:\Jenkins\foo\bar
sandbox";
^ illegal escape sequence
Great. Escaping issues even here in the Wiki-text! It was meant to be
and
respectively.