func RawModeOn() (quit chan struct{}, err error) {
	echoLockMutex.Lock()
	defer echoLockMutex.Unlock()
	if echoLocked {
		err = errLocked
		return
	}
	if err = lockEcho(); err != nil {
		return
	}
	echoLocked = true
	quit = make(chan struct{}, 1)
	go catchTerminate(quit)
	return
}
RawModeOn switches terminal to raw mode
package termutil
import (
	"errors"
	"os"
	"os/signal"
	"sync"
)
var echoLocked bool
var echoLockMutex sync.Mutex
var errLocked = errors.New("terminal locked")