Skip to content

Commit

Permalink
exec: forward command output to stderr instead of stdout on --show-ta…
Browse files Browse the repository at this point in the history
…sk-output

When "--show-task-output" is passed to "baur run", the command output is now
written to stderr instead of stdout.
Stderr fits better the output is for diagnostic purposes.
  • Loading branch information
fho committed Jan 3, 2024
1 parent 2a2d040 commit 3d89c76
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion internal/command/run.go
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ func (c *runCmd) run(_ *cobra.Command, args []string) {
c.taskRunnerRoutinePool = routines.NewPool(c.taskRunnerGoRoutines)
c.taskRunner = baur.NewTaskRunner()
if c.showOutput && !verboseFlag {
c.taskRunner.LogFn = stdout.Printf
c.taskRunner.LogFn = stderr.Printf
}

c.dockerClient, err = docker.NewClient(log.StdLogger.Debugf)
Expand Down

0 comments on commit 3d89c76

Please sign in to comment.