SPUG: shell script event loops + wrapping shell utilities

Matt Tucker tuck at whistlingfish.net
Fri Apr 19 20:00:59 CDT 2002

-- dancerboy <dancerboy at strangelight.com> spake thusly:

> So, I wanted to add some minor functionality to a couple of shell
> programs (telnet and ftp, specifically) and the simplest way seemed
> to be simply to wrap them in a Perl script, i/e simply make a Perl
> script that opens the program, and pipes input from the terminal
> (keystrokes) through to the program, and passes characters output
> from the program back to the terminal -- occasionally adding some
> extra keystrokes of its own (the added functionality) but mostly just
> acting as a "bidirectional pipe" between the program and the terminal.

I know this is a Perl list and all that, but have you considered using
expect? It seems like it's designed for this sort of thing.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 232 bytes
Desc: not available
Url : http://mail.pm.org/archives/spug-list/attachments/20020419/b2c104d6/attachment.bin

More information about the spug-list mailing list