Hi, Op maandag 12 oktober 2009 14:23 schreef Stephen J. Turnbull: > Trent W. Buck writes: > > > > You can read directly from the terminal by opening "/dev/tty". > > > > Hmm... is it *always* /dev/tty? I thought it was e.g. /dev/pts/73 > > sometimes. > > On the systems I know of /dev/tty will always work. It may be an > alias for /dev/pts/73, though. But ... less works over an ssh > connection, and obviously opening /dev/tty isn't the right thing > there.
AFAICT the kernel performs some magic and gives any process that opens "/dev/tty" a handle to the terminal that it's actually on. I don't know what rules it uses to determine which terminal a process "is actually on", but it seems to do so very well. Anyway I can do a "echo aargh > /dev/tty" in my KDE terminal emulator and see the output. Reinier
signature.asc
Description: This is a digitally signed message part.
_______________________________________________ darcs-users mailing list [email protected] http://lists.osuosl.org/mailman/listinfo/darcs-users
