|
From: | Matthew Woehlke |
Subject: | Re: grep help with cygwin |
Date: | Thu, 03 May 2007 12:14:13 -0500 |
User-agent: | Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.0.10) Gecko/20070221 Thunderbird/1.5.0.10 Mnenhy/0.7.4.0 |
sdnabble wrote:
grep "Some_String_" file1.txt | grep [^P]LACED > tempout.txt Right away it didn't work. For some reason I can't say look for Some_String_ NOT containing the word PLACED. So I looked and looked through documentation and could not figure out why this doesn't work. Isn't that how to use "NOT"?
RTFM. It is, if you want to look for all six-character strings ending with "LACED" that are not "PLACED". You probably want '-v'.
Can I append stuff to file1.txt once I get the needed XY information?
Yes. RTF bash M, in particular see "redirection". -- Matthew Disadvantage: Bad Puns [-5]You constantly utter puns so egregious as to cause mental distress to anyone hearing them. This can, however, be used to distract enemies.
[Prev in Thread] | Current Thread | [Next in Thread] |