Do not add a newline between a stream of info messages. The contract is that these will just be appended continguously. (#1688)

This commit is contained in:
CyrusNajmabadi 2018-08-02 10:55:15 -04:00 committed by GitHub
parent b2c91f7c24
commit 58ae413bca
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 1 additions and 7 deletions

View file

@ -734,11 +734,7 @@ func (display *ProgressDisplay) mergeStreamPayloadsToSinglePayload(
payloads []engine.DiagEventPayload) engine.DiagEventPayload {
buf := bytes.Buffer{}
for i, p := range payloads {
if i != 0 {
buf.WriteString("\n")
}
for _, p := range payloads {
buf.WriteString(display.renderProgressDiagEvent(p, false /*includePrefix:*/))
}

View file

@ -24,7 +24,6 @@ import (
"strings"
"sync/atomic"
"time"
"unicode"
multierror "github.com/hashicorp/go-multierror"
"github.com/pkg/errors"
@ -120,7 +119,6 @@ func newPlugin(ctx *Context, bin string, prefix string, args []string) (*plugin,
break
}
msg = strings.TrimRightFunc(msg, unicode.IsSpace)
if strings.TrimSpace(msg) != "" {
if stderr {
ctx.Diag.Infoerrf(diag.StreamMessage("" /*urn*/, msg, errStreamID))