Details
-
Bug
-
Status: Closed
-
Minor
-
Resolution: Fixed
-
None
-
None
-
Windows/Cygwin; probably all versions affected
-
Patch
Description
The issue was raised in this groovy-user discussion:
http://groovy.329449.n5.nabble.com/How-to-properly-escape-groovy-one-liners-for-bash-tp5712274.html
The following statement is supposed to throw a MultipleCompilationErrorsException but instead if gives "bad substitution" message from the shell:
groovy -e 'println "${a.author}"'
The problem is that on Cygwin the startGroovy script does additional processing that breaks some code that is given as an argument to the '-e' option.
The attached patch fixes this problem if the Bash is used, which in all reasonable conditions seems to be the case.