On Tue, Jan 22, 2002 at 03:00:47PM +1000, Matthew Melvin wrote:
> I think just leave off the second {} so you give it the target dir and the 
> target name is infered.  So...
> 
> find /mnt/cdrom -type f -exec cp {} /home/BigDog/files/source/ \;

I will point out that there are two potential problems with this:

        -If there are any spaces in the filenames, this will break.
         Enclose the braces in double-quotes to prevent this.

        -If there are any files with the same name but residing in
         different directories, they'll be overwritten; at the end,
         you'll only have the last filename.  This isn't as easily
         corrected; feed the output of the find to a script that builds
         a list of files and uniquely renames duplicates, perhaps.

Cheers,
-- 
        Dave Ihnat
        [EMAIL PROTECTED]



_______________________________________________
Redhat-list mailing list
[EMAIL PROTECTED]
https://listman.redhat.com/mailman/listinfo/redhat-list

Reply via email to