Can Telnet input come from two sources?
Steve Hayman
sahayman at iuvax.cs.indiana.edu
Fri Jul 6 04:27:00 AEST 1990
>I'm trying to setup a front end for the Telnet program for use
>by novices.
Get the program 'expect', by Don Libes, available for ftp from
durer.cme.nist.gov . This program was written up in the most recent
Usenix proceedings - I think it will do what you want. expect
can be used to control interactive programs such as telnet - you can
have it feed telnet some lines from a file, and then switch
telnet's input so it comes from the user. Sounds like just what
you need.
Here's the README file:
This is the README file from "expect", a program that performs
programmed dialogue with other interactive programs. It is briefly
described by its man page, expect(1). More examples and further
discussion about implementation, philosophy, and design are in
"expect: Curing Those Uncontrollable Fits of Interaction" by Don
Libes, Proceedings of the Summer 1990 USENIX Conference, Anaheim,
California, June 11-15, 1990.
expect was designed and written by Don Libes, January - April, 1990.
Design and implementation of this program was paid for by U.S. tax
dollars. Therefore it is public domain. However, the author and NIST
would appreciate credit if this program or parts of it are used.
expect may be ftp'd as pub/expect.shar.Z from durer.cme.nist.gov. If
you cannot ftp, you may request email copies by mailing to "library@
cme.nist.gov". The contents of the message should be (no subject
line) "send pub/expect.shar.Z". Once you have retrieved the system,
please read the INSTALL file. The paper mentioned above can be ftp'd
separately as pub/expect.ps.Z.
expect requires Tcl. Tcl may be ftp'd as pub/tcl.tar.Z from
ucbvax.berkeley.edu. If not available, a potentially older but
working version of Tcl may be ftp'd as pub/tcl.tar.Z from
durer.cme.nist.gov. If you cannot ftp, you may request email copies
of Tcl by writing to ouster at sprite.berkeley.edu.
expect is known to work on SunOS 4.0 systems but it does nothing Sun
specific and will probably work on most BSD-derived systems. While
it has not been compiled on SV or POSIX systems, I have made
provisions enough so that probably only minor changes remain. (See
the Makefile for more info.) This might be presumptive however, as I
recently looked at the process control in gnuemacs and am amazed how
much pain it took them to make it portable. Perhaps someday I will
change to using their code. I would be willing to work with you to
complete a port.
Although I can't promise anything in the way of support, I'd be
interested to hear about your experiences using it (either good or
bad). I'm also interested in hearing bug reports (please include
version # reported by expect -d) and suggestions for improvement even
though I can't promise to implement them immediately.
Please send money, love letters, and bug reports to:
Don Libes
National Institute of Standards and Technology
Bldg 220, Rm A-127
Gaithersburg, MD 20899
(301) 975-3535
libes at cme.nist.gov or uunet!cme-durer!libes
Hope this helps.
..steve
--
Steve Hayman Workstation Manager Computer Science Department Indiana U.
sahayman at iuvax.cs.indiana.edu (812) 855-6984
More information about the Comp.unix.questions
mailing list