[SGVLUG] expect is very neat
Robert Leyva
mrflash818 at geophile.net
Mon Sep 11 22:10:17 PDT 2006
I wanted to create a script that would do a cvs update without me having
to input the password.
I found "expect", and it is really nice!
since I am a debian person, I only had to do: sudo aptitude install expect
For my need, I am fetching from a CVS repository that is read-only and
doesn't require a password, that is why the send just gives a newline
character.
Here is my autoFetchFromCVS.sh
robert at pip ~/projects/clamav cat ./autoFetchFromCVS.sh
#!/usr/bin/expect -f
spawn ./fetchFromCVS.sh
expect "assword"
send "\n"
expect eof
robert at pip ~/projects/clamav
--
"Knowledge is Power" -- Francis Bacon
Robert Leyva
mrflash818 at geophile.net
More information about the SGVLUG
mailing list