in reply to Using Basename
The clauses of a find are carried out in order, left to right. If a clause succeeds, processing continues; if it fails, this candidate is abandoned and the next file tested.
Presumably, what you really want is to defer printing until after you have selected only '*.pl' files:
.... `find '.' -type f -name '*.pl' -print` ....
info find or man find is your friend. In particular, watch for the case where you want to match one of two patterns, using -o. You have to group the patterns using parentheses, escaped to prevent the shell from interpreting them:
find . \( -name '.pl' -o -name '*.pod' \) -print
--
TTTATCGGTCGTTATATAGATGTTTGCA
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Using Basename
by blueapache (Acolyte) on Nov 18, 2003 at 08:48 UTC |