#!/usr/bin/ruby tty = open("/dev/tty", "r") while (c = tty.gets) puts c end