Thanks msw and ziyu_huang. I copied the technique from JLine, and
after many silly errors on my part, it now works well.
I have used exec.Run() with argv of: "/bin/stty", "-F", "/dev/tty", "-
icanon", "min", "1"
On Dec 14, 2:45 am, ziyu_huang <
ziyu4hu...@gmail.com> wrote:
> Actually, it's portable enough for most unix system.
> You can see how JLine use it.
>
> On 12月14日, 上午10時39分, msw <
matt.wart...@gmail.com> wrote:
>
> > There's always exec.Run("stty" ....) but it gives me the non-portable
> > willies.
>
> > On Dec 13, 5:22 am, ray <
r...@hollett.demon.co.uk> wrote:
>
> > > When using the read function in the OS package, Go seems to use Linux
> > > cooked mode. I cannot see a flag value to add to os.Open() to request
> > > Linuxrawmode. What I want to do is read a character from standard-in