ollama/readline/readline_unix.go
Michael Yang 2bb2bdd5d4 fix lint
2024-01-09 09:36:58 -08:00

18 lines
273 B
Go

//go:build !windows
package readline
import (
"syscall"
)
func handleCharCtrlZ(fd int, termios *Termios) (string, error) {
if err := UnsetRawMode(fd, termios); err != nil {
return "", err
}
_ = syscall.Kill(0, syscall.SIGSTOP)
// on resume...
return "", nil
}