Method: IO#noecho

Defined in:
console/console.c

#noecho {|io| ... } ⇒ Object

Yields self with disabling echo back.

STDIN.noecho(&:gets)

will read and return a line without echo back.

You must require 'io/console' to use this method.

Yields:

  • (io)

560
561
562
563
564
# File 'console/console.c', line 560

static VALUE
console_noecho(VALUE io)
{
    return ttymode(io, rb_yield, io, set_noecho, NULL);
}