How to call external shell in Groovy?
Going on learning Groovy, I faced the following case: how to call an external shell (or MS-DOS) command from a Groovy script?
It is very easy. The following example show how to display the Subversion status of the current folder:
[java]def proc = "svn st"
def sb = new StringBuffer()
proc.consumeProcessErrorStream(sb)
println proc.text + "\n" + sb.toString()
[/java]