|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
||||
|
||||
|
Excluding certain filetypes from FIND
As I type this I have a FIND running in another window. It's been going for quite some time because of the huge number of images stored on the server. I'm not very good at figuring things out from MAN pages (maybe if they were WOMAN pages...
) so I'm asking here if someone can show me ho I would modify my find to exclude jpg's and gif's.Here's what I currently use: find "some term" * -print Any help appreciated. ![]() |
|
#2
|
||||
|
||||
|
Pass your output through an inverted grep (e.g. - you supply a pattern, it tells you what DOESN'T match the pattern) using a pipe. The grep switch for inversion is '-v'.
|
|
#3
|
||||
|
||||
|
Thanks, I'll give it a try.
![]() |
|
#4
|
|||
|
|||
|
find also supports the ! operator (meaning "not" ) like this
Code:
find /path ! -name \*.jpg ! -name \*.gif |
![]() |
| Viewing: Dev Shed Forums > Operating Systems > UNIX Help > Excluding certain filetypes from FIND |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|