Visit the LQ Articles and Editorials section
Go Back > Forums > Linux Forums > Linux - Software
User Name
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.


  Search this Thread
Old 06-18-2007, 02:40 PM   #1
Registered: Sep 2005
Location: USA, TN
Distribution: CentOS & Ubuntu for Desktop
Posts: 454

Rep: Reputation: 31
searching for Text within files.

i have a problem with a spamassassin rule. I know which rule but i don't know which file the rule is saved into. The rule name is BIZ_TLD
#cd /etc/mail/spamassassin
#cat * | grep "BIZ_TLD"
and it's coming back with this:
score BIZ_TLD           1.022   # Increased from 0.7: JGRAY 21-Feb-2005
i simply want to remove the above line but i don't know in which file it's located.
i tried:
#cat *.cf | grep -l "BIZ_TLD"
which is coming back with this output:
(standard input)
any ideas?
Old 06-18-2007, 02:46 PM   #2
Senior Member
Registered: Oct 2005
Location: UK
Distribution: Slackware
Posts: 1,847

Rep: Reputation: 128Reputation: 128
Originally Posted by man grep
-H, --with-filename
Print the filename for each match.
grep -H "BIZ_TLD" *
would output the filename in which the matching text was found.
Old 06-18-2007, 02:56 PM   #3
Registered: Sep 2005
Location: USA, TN
Distribution: CentOS & Ubuntu for Desktop
Posts: 454

Original Poster
Rep: Reputation: 31
it worked.

thanks ... easy enough


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
LQ searching with text browsers dive LQ Suggestions & Feedback 1 12-31-2006 11:16 AM
Searching for text within pdfs - possible? will103 Linux - Software 6 12-05-2005 09:41 AM
text searching sopiaz57 Linux - Software 4 06-02-2005 01:00 PM
Searching text files by content will103 Linux - Software 1 01-24-2005 07:43 AM
searching inside text files minm Linux - Newbie 2 01-08-2005 11:56 PM

All times are GMT -5. The time now is 09:32 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration