#!/usr/bin/env groovy /* * Runs shell command and prints back stdout and stderr */ command='ls -al' println new ProcessBuilder('sh','-c',command).redirectErrorStream(true).start().text