var logFilePath … var alsoToStdOut … var redirectStderr … func main() { … } func configureAndRun() error { … } // cmdInfo generates a useful look at what the command is for printing/debug. func cmdInfo(cmd *exec.Cmd) string { … } // setupSigHandler will forward any termination signals to the process func setupSigHandler(process *os.Process) { … }