* On Wed, May 11, 2005 at 01:48:35PM +1000, Simon wrote: > Hi all, > Why is the following script ripping out every directory rather than just > those in 'studentfile' > > #!/bin/bash > while read name; do > cd $name
Fails here if directory $name doesnt exist; next line deletes everything. > rm -fvr * > cd .. > rmdir $name > done < studentlist -- Sonia Hamilton. GPG key A8B77238. . Type cat vmlinuz > /dev/audio to hear the voice of $DEITY. -- SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/ Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html