Let's get to the core problem

Avery Fay afay at pop.ma.ultranet.com
Sat Jun 24 17:13:50 PDT 2000


>Related to this last item, I have a shell programming question.  I 
wanted to
>write a shell function to copy directories from one place to another 
recurs-
>ively, creating sub-dirs as needed and checking for overwrites.  This 
is one
>of those functions in vars.  I found that shell functions can't be 
recursive,
>so I need to get a directory listing into a shell variable and step 
through
>each item.  Easy enough to create the variable - dirvar=`ls`.  But how 
do you
>get one item out of that variable?  I remember doing this before, 
sucking out
>one word from the variable, but I can't remember how.  Any ideas?

The only thing I can think of write now is to use cut.

Avery Fay


--
Mail archive: http://www.pcrdallas.com/mail-archives/alfs-discuss
IRC access: server: irc.linuxfromscratch.org port: 6667 channel: #LFS
Unsubscribe: email alfs-discuss-request at linuxfromscratch.org and put
"unsubscribe" (without the quotation marks) in the body of the message
(no subject is required)



More information about the alfs-discuss mailing list