Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 12 Aug 2010 12:35:58 +0100
From:      Arthur Chance <freebsd@qeng-ho.org>
To:        "Jack L. Stone" <jacks@sage-american.com>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: Grepping a list of words
Message-ID:  <4C63DC9E.3060705@qeng-ho.org>
In-Reply-To: <3.0.1.32.20100811180022.00ee4250@sage-american.com>
References:  <3.0.1.32.20100811180022.00ee4250@sage-american.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On 08/12/10 00:00, Jack L. Stone wrote:
> Kindly appreciate help with how to grep (or similar) a list of words to
> determine if any of them are in a file rather than grepping one word at a
> time.

fgrep, aka grep -F

A snippet from "man grep":

        -F, --fixed-strings
               Interpret  PATTERN as a list of fixed strings, separated
	      by newlines, any of which is to be matched.




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4C63DC9E.3060705>