Skip to content

Commit 19cd199

Browse files
committed
Add WSEP_TTY variable
1 parent 5d2bff0 commit 19cd199

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

localexec.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,8 @@ func (l LocalExecer) Start(ctx context.Context, c Command) (Process, error) {
9090
}
9191

9292
if c.TTY {
93+
// This special WSEP_TTY variable helps debug unexpected TTYs.
94+
process.cmd.Env = append(process.cmd.Env, "WSEP_TTY=true")
9395
process.tty, err = pty.Start(process.cmd)
9496
if err != nil {
9597
return nil, xerrors.Errorf("start command with pty: %w", err)

0 commit comments

Comments
 (0)