[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Unattended package install.




	Henry Hollenberg     speed@barney.iamerica.net 


On Sat, 4 Apr 1998, Philip Hands wrote:

> > 
> > I tried it and it seemed to die in the middle of the generation of
> > it's script.  It might have something to do with my script hanging at
> > the end though.
> 
> Just run the interactive bits through the expect script.  i.e.:
> 
>   /usr/doc/expect5.24/examples/autoexpect -f inewsinn.exp  \
>       dpkg -i `find . -name "inewsinn_*.deb"`
> 
> and fill in the blanks.  Once done, have a look at the new script.  Each 
> prompt should have been turned into an ``expect'' statement, but there will be 
> a lot of stuff you don't need, and you need to make the script capable of 
> surviving variable prompts.

Ok, I gave it a shot with kernel-source-2.0.30_2.0.20-7.deb using
autoexpect.  Something went wrong as I only got three lines of output:

spawn dpkg -i.....
match_max 100000
expect eof

So I tried to just wing it after I noticed the repetitive pattern of
expect
send
expect
send
etc

But I don't seem to be doing something correctly.  The package install
runs but it pukes when it get's to the stage of accepting my input or
"send" commands.  Here is the script I was using:

#!/usr/bin/expect -f
#

set timeout -1
spawn dpkg -i/cdrom/bo/binary-i386/devel/kernel-source-2.0.30_2.0.30-7.deb 
match_max 100000
expect -exact "Please supply the full name of the local kernel maintainer"
send -- "Henry Hollenberg\r"
expect -exact "Please supply the email address of the local kernel 
maintainer"
send -- "speed@barney.iamerica.net\r"
expect eof


Anybody see where I've gone astray?

hgh


--
To UNSUBSCRIBE, email to debian-devel-request@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org


Reply to: