Source File
start.go
Belonging Package
github.com/creack/pty
//go:build !windows// +build !windowspackage ptyimport ()// StartWithSize assigns a pseudo-terminal tty os.File to c.Stdin, c.Stdout,// and c.Stderr, calls c.Start, and returns the File of the tty's// corresponding pty.//// This will resize the pty to the specified size before starting the command.// Starts the process in a new session and sets the controlling terminal.func ( *exec.Cmd, *Winsize) (*os.File, error) {if .SysProcAttr == nil {.SysProcAttr = &syscall.SysProcAttr{}}.SysProcAttr.Setsid = true.SysProcAttr.Setctty = truereturn StartWithAttrs(, , .SysProcAttr)}
![]() |
The pages are generated with Golds v0.8.2. (GOOS=linux GOARCH=amd64) Golds is a Go 101 project developed by Tapir Liu. PR and bug reports are welcome and can be submitted to the issue list. Please follow @zigo_101 (reachable from the left QR code) to get the latest news of Golds. |