provisioner/shell: Trim whitespace on output
This commit is contained in:
parent
684df67ca6
commit
fdda64f48e
|
@ -10,6 +10,7 @@ import (
|
||||||
"io"
|
"io"
|
||||||
"log"
|
"log"
|
||||||
"os"
|
"os"
|
||||||
|
"strings"
|
||||||
"time"
|
"time"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@ -90,9 +91,9 @@ OutputLoop:
|
||||||
for {
|
for {
|
||||||
select {
|
select {
|
||||||
case output := <-stderrChan:
|
case output := <-stderrChan:
|
||||||
ui.Say(output)
|
ui.Say(strings.TrimSpace(output))
|
||||||
case output := <-stdoutChan:
|
case output := <-stdoutChan:
|
||||||
ui.Say(output)
|
ui.Say(strings.TrimSpace(output))
|
||||||
case exitStatus := <-exitChan:
|
case exitStatus := <-exitChan:
|
||||||
log.Printf("shell provisioner exited with status %d", exitStatus)
|
log.Printf("shell provisioner exited with status %d", exitStatus)
|
||||||
break OutputLoop
|
break OutputLoop
|
||||||
|
|
Loading…
Reference in New Issue