[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Sheflug] cpio problems with Expect
Hi Guys
I have an Expect script that I use to tar some stuff, and ftp over night to
another computer.
Recently, the source directory has got rather deep, and has some long file
names, tar has started to get picky, so I'm trying to achieve the same using
cpio.
My tar line was...
exec tar cvf $tar_temp/$tar_name $tar_path
I replaced this with...
exec find $tar_path -print | cpio -o > $tar_temp/$tar_name
Which seems to start, and then stop after a few seconds with...
while executing
"exec find $tar_path -print | cpio -o > $tar_temp/$tar_name"
(file "./backup" line 27)
I *think* this is something to do with how the find command is started...
but this is a complete guess, based on the fact that if I run the line on
the shell, it works!
I have tried to rewrite the line giving cpio a list of files rather than
using stdin; but couldn't get this to work either.
I can't work out what version of cpio I have, --version -v etc.. doesn't
produce anything, and man isn't much help. I'm running SCO Openserver 5.0.5.
Amy help would be much appreciated...
Gareth
___________________________________________________________________
Sheffield Linux User's Group -
http://www.sheflug.co.uk/mailfaq.html
GNU the choice of a complete generation.