Skip to content

Commit

Permalink
Dagger Shell output is not ready for UX integration
Browse files Browse the repository at this point in the history
  • Loading branch information
sourishkrout committed Feb 6, 2025
1 parent 597b87e commit 5554e6a
Showing 1 changed file with 9 additions and 8 deletions.
17 changes: 9 additions & 8 deletions internal/runner/service.go
Original file line number Diff line number Diff line change
Expand Up @@ -358,15 +358,16 @@ func (r *runnerService) Execute(srv runnerv1.RunnerService_ExecuteServer) error
}

opts := &startOpts{}
// todo(sebastian): dagger-shell is not UX integration ready yet
// special-case Dagger Shell to write the shell's stdout to stderr
if cfg.CommandMode == CommandModeDaggerShell {
opts.TtyAssignment = func(c *command) {
c.cmd.Stdin = c.tty
// technically wrong but in v1 we optimize for the least amount of downstream changes
c.cmd.Stdout = c.Stderr
c.cmd.Stderr = c.tty
}
}
// if cfg.CommandMode == CommandModeDaggerShell {
// opts.TtyAssignment = func(c *command) {
// c.cmd.Stdin = c.tty
// // technically wrong but in v1 we optimize for the least amount of downstream changes
// c.cmd.Stdout = c.Stderr
// c.cmd.Stderr = c.tty
// }
// }
if err := cmd.StartWithOpts(cmdCtx, opts); err != nil {
return err
}
Expand Down

0 comments on commit 5554e6a

Please sign in to comment.