Skip to content

Commit

Permalink
add verbosity
Browse files Browse the repository at this point in the history
Signed-off-by: Pavel Okhlopkov <[email protected]>
  • Loading branch information
Pavel Okhlopkov committed Dec 5, 2024
1 parent 80919f9 commit 7cbd786
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions pkg/executor/executor.go
Original file line number Diff line number Diff line change
Expand Up @@ -108,10 +108,10 @@ func (e *Executor) RunAndLogLines(logLabels map[string]string) (*CmdUsage, error
err := e.cmd.Run()
if err != nil {
if len(stdErr.Bytes()) > 0 {
return nil, fmt.Errorf("%s", stdErr.String())
return nil, fmt.Errorf("stderr: %s", stdErr.String())
}

return nil, err
return nil, fmt.Errorf("cmd run: %w", err)
}

var usage *CmdUsage
Expand All @@ -129,7 +129,7 @@ func (e *Executor) RunAndLogLines(logLabels map[string]string) (*CmdUsage, error
}
}

return usage, err
return usage, nil
}

type proxyLogger struct {
Expand Down Expand Up @@ -175,7 +175,7 @@ func (pl *proxyLogger) Write(p []byte) (int, error) {
// fall back to using the logger
pl.logger.Info(string(p))

return len(p), err
return len(p), nil
}

// logEntry.Log(log.FatalLevel, string(logLine))
Expand Down

0 comments on commit 7cbd786

Please sign in to comment.