Is it possible to wrap a `find` command on multiple lines in a script?  
This is what I'm using now:

foreach $dir_to_search (@dirs_to_search) {
        $dir_count--;
        @files = map { 
                s|/home/user/public_html ||;
                $_; 
        } `find $dir_to_search -name cache -prune -o -name tmp -prune -o -name 
session -prune -o -print`;

        I'd like to be able to do something like this to make it more readable:

foreach $dir_to_search (@dirs_to_search) {
        $dir_count--;
        @files = map { 
                s|/home/user/public_html||;
                $_;
        } `find $dir_to_search 
                -name cache -prune 
                -o -name tmp -prune 
                -o -name session -prune 
                -o -print`;

however my searches have turned up nothing.  Using returns, commas, 
backslashes, or concatenation breaks the find.  Does anyone know if this is 
doable?

Thanks,
Frank
SurfShopCART
--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/


Reply via email to