From owner-freebsd-questions Fri Feb 26 21: 3:12 1999 Delivered-To: freebsd-questions@freebsd.org Received: from pobox.com (kronos-2-183.mdm.mkt.execpc.com [169.207.86.121]) by hub.freebsd.org (Postfix) with ESMTP id F15DC150D7 for ; Fri, 26 Feb 1999 21:03:10 -0800 (PST) (envelope-from hamilton@pobox.com) Received: from pobox.com (localhost [127.0.0.1]) by pobox.com (Postfix) with ESMTP id DFDD946381; Fri, 26 Feb 1999 23:02:46 -0600 (CST) To: Brendan Kosowski Cc: FreeBSD Questions Subject: Re: grep question In-reply-to: Your message of "Sat, 27 Feb 1999 15:52:51 +1100." Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Fri, 26 Feb 1999 23:02:46 -0600 From: Jon Hamilton Message-Id: <19990227050246.DFDD946381@pobox.com> Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG In message , Brendan Kosowski wrote: } } } How do I search for a string if it contains quotation marks ? } } " is used by grep to mark the start and end of a string : } ( eg: grep "string" filename ). } } ie: How do I tell grep to search for: ( the dog said "woof" ) There is (as is usual for UNIX) more than one way to do that, but one simple solution is: $ grep 'the dog said "woof"' filename -- Jon Hamilton hamilton@pobox.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message