Omit any empty lines containing STX/ETX markers

This commit is contained in:
Sander van Harmelen 2018-10-11 22:08:09 +02:00
parent 8826d67acf
commit c08cd597c5
2 changed files with 6 additions and 0 deletions

View File

@ -165,6 +165,9 @@ func (b *Remote) opApply(stopCtx, cancelCtx context.Context, op *backend.Operati
scanner := bufio.NewScanner(logs)
for scanner.Scan() {
if scanner.Text() == "\x02" || scanner.Text() == "\x03" {
continue
}
if b.CLI != nil {
b.CLI.Output(b.Colorize().Color(scanner.Text()))
}

View File

@ -208,6 +208,9 @@ func (b *Remote) plan(stopCtx, cancelCtx context.Context, op *backend.Operation,
scanner := bufio.NewScanner(logs)
for scanner.Scan() {
if scanner.Text() == "\x02" || scanner.Text() == "\x03" {
continue
}
if b.CLI != nil {
b.CLI.Output(b.Colorize().Color(scanner.Text()))
}