Linux Recursive GREP search excluding directories example

This command will search for text inside files in a directory while excluding some directories you do not want to search in.

This is helpful when a search is going slow due to a directory that might contain thousands of files that you are not interested in searching through, such as an images or cache directory.

grep -r –exclude-dir=product_images –exclude-dir=cache –exclude-dir=.svn search term *

 

 

 


Amber Led Emergency Strobe Beacon Lights Bar with Magnetic Mount and 8 Flash Mod picture

Amber Led Emergency Strobe Beacon Lights Bar with Magnetic Mount and 8 Flash Mod

$32.97



Mercedes Medical Platinum Line Flash Freeze Spray 10 oz. picture

Mercedes Medical Platinum Line Flash Freeze Spray 10 oz.

$24.93



16GB/32GB Mini Voice Activated Digital Sound Audio Recorder USB Disk Flash Drive picture

16GB/32GB Mini Voice Activated Digital Sound Audio Recorder USB Disk Flash Drive

$14.51



2in1 Mini Voice Activated 8GB Digital Sound Audio Recorder USB Flash Drive Disk picture

2in1 Mini Voice Activated 8GB Digital Sound Audio Recorder USB Flash Drive Disk

$15.54



BUG USB Voice Activated Recorder Digital Mini Audio Listening Device Dictaphone picture

BUG USB Voice Activated Recorder Digital Mini Audio Listening Device Dictaphone

$16.12



Mini Voice Activated Recorder Spy Listening Device Audio Microphone MP3 Player picture

Mini Voice Activated Recorder Spy Listening Device Audio Microphone MP3 Player

$16.87



BUG USB Voice Activated Recorder Digital Mini Audio Listening Device Dictaphone picture

BUG USB Voice Activated Recorder Digital Mini Audio Listening Device Dictaphone

$14.51



BUG USB Voice Activated Recorder Digital Mini Audio Listening Device Dictaphone picture

BUG USB Voice Activated Recorder Digital Mini Audio Listening Device Dictaphone

$14.51



Warning Arc Flash Shock  Sticker Decal Label Electrical Safety  picture

Warning Arc Flash Shock Sticker Decal Label Electrical Safety

$75.50



Flash Cuff 2.5

Flash Cuff 2.5" Female AH216

$6.23



Powered by WordPress. Designed by WooThemes