<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: script in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/script/m-p/2784798#M78145</link>
    <description>Hi&lt;BR /&gt;If this pattern is alone on a line:&lt;BR /&gt;grep -v j.k &lt;FILENAME&gt;&lt;/FILENAME&gt;</description>
    <pubDate>Tue, 13 Aug 2002 06:42:22 GMT</pubDate>
    <dc:creator>Leif Halvarsson_2</dc:creator>
    <dc:date>2002-08-13T06:42:22Z</dc:date>
    <item>
      <title>script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/script/m-p/2784795#M78142</link>
      <description>Hi,&lt;BR /&gt;I have a file called test.txt (1000 lines)in unix with cotents.&lt;BR /&gt;a.b&lt;BR /&gt;f.c&lt;BR /&gt;d.b&lt;BR /&gt;b.h&lt;BR /&gt;j.k&lt;BR /&gt;...&lt;BR /&gt;...&lt;BR /&gt;How can I delete a specific pattern example&lt;BR /&gt;j.k in this file by shell script.&lt;BR /&gt;&lt;BR /&gt;regards,&lt;BR /&gt;U.SivaKumar</description>
      <pubDate>Tue, 13 Aug 2002 06:19:29 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/script/m-p/2784795#M78142</guid>
      <dc:creator>U.SivaKumar_2</dc:creator>
      <dc:date>2002-08-13T06:19:29Z</dc:date>
    </item>
    <item>
      <title>Re: script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/script/m-p/2784796#M78143</link>
      <description>Hi,&lt;BR /&gt;cat [filename] | awk '!/j\.k/ { print }'&lt;BR /&gt;&lt;BR /&gt;Is that what you are looking for ?&lt;BR /&gt;&lt;BR /&gt;Regards,&lt;BR /&gt;Tom</description>
      <pubDate>Tue, 13 Aug 2002 06:39:27 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/script/m-p/2784796#M78143</guid>
      <dc:creator>Tom Geudens</dc:creator>
      <dc:date>2002-08-13T06:39:27Z</dc:date>
    </item>
    <item>
      <title>Re: script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/script/m-p/2784797#M78144</link>
      <description>&lt;BR /&gt;What about grep -v '^j.k' test.txt ?&lt;BR /&gt;&lt;BR /&gt;Or are you looking for more complex pattern matching?&lt;BR /&gt;&lt;BR /&gt;Stanley.</description>
      <pubDate>Tue, 13 Aug 2002 06:41:22 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/script/m-p/2784797#M78144</guid>
      <dc:creator>Stanley Merkx</dc:creator>
      <dc:date>2002-08-13T06:41:22Z</dc:date>
    </item>
    <item>
      <title>Re: script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/script/m-p/2784798#M78145</link>
      <description>Hi&lt;BR /&gt;If this pattern is alone on a line:&lt;BR /&gt;grep -v j.k &lt;FILENAME&gt;&lt;/FILENAME&gt;</description>
      <pubDate>Tue, 13 Aug 2002 06:42:22 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/script/m-p/2784798#M78145</guid>
      <dc:creator>Leif Halvarsson_2</dc:creator>
      <dc:date>2002-08-13T06:42:22Z</dc:date>
    </item>
    <item>
      <title>Re: script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/script/m-p/2784799#M78146</link>
      <description>This is one way to do it.&lt;BR /&gt;&lt;BR /&gt;#!/usr/bin/ksh&lt;BR /&gt;PATTERN=j.k&lt;BR /&gt;cat - &amp;lt;&amp;lt; EOF | ed -s test.txt&lt;BR /&gt;/$PATTERN&lt;BR /&gt;d&lt;BR /&gt;w&lt;BR /&gt;q&lt;BR /&gt;EOF</description>
      <pubDate>Tue, 13 Aug 2002 06:42:59 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/script/m-p/2784799#M78146</guid>
      <dc:creator>Tommy Palo</dc:creator>
      <dc:date>2002-08-13T06:42:59Z</dc:date>
    </item>
    <item>
      <title>Re: script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/script/m-p/2784800#M78147</link>
      <description># perl -ne '/j\.k/||print' infile</description>
      <pubDate>Tue, 13 Aug 2002 07:10:28 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/script/m-p/2784800#M78147</guid>
      <dc:creator>H.Merijn Brand (procura</dc:creator>
      <dc:date>2002-08-13T07:10:28Z</dc:date>
    </item>
    <item>
      <title>Re: script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/script/m-p/2784801#M78148</link>
      <description>Off the command line:&lt;BR /&gt;sed -e '/j.k/d' test.txt&lt;BR /&gt;&lt;BR /&gt;In a script:&lt;BR /&gt;#!/usr/bin/ksh&lt;BR /&gt;&lt;BR /&gt;eval sed -e '/$1/' test.txt&lt;BR /&gt;&lt;BR /&gt;#end script&lt;BR /&gt;&lt;BR /&gt;Then invoke as ./script.sh j.k&lt;BR /&gt;&lt;BR /&gt;Cheers&lt;BR /&gt;Steven</description>
      <pubDate>Wed, 14 Aug 2002 02:09:07 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/script/m-p/2784801#M78148</guid>
      <dc:creator>Procnus</dc:creator>
      <dc:date>2002-08-14T02:09:07Z</dc:date>
    </item>
    <item>
      <title>Re: script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/script/m-p/2784802#M78149</link>
      <description>Oops...&lt;BR /&gt;#!/usr/bin/ksh &lt;BR /&gt;&lt;BR /&gt;eval sed -e '/$1/d' test.txt &lt;BR /&gt;&lt;BR /&gt;#end script &lt;BR /&gt;&lt;BR /&gt;Then invoke as ./script.sh j.k &lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Steven</description>
      <pubDate>Wed, 14 Aug 2002 02:42:51 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/script/m-p/2784802#M78149</guid>
      <dc:creator>Procnus</dc:creator>
      <dc:date>2002-08-14T02:42:51Z</dc:date>
    </item>
    <item>
      <title>Re: script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/script/m-p/2784803#M78150</link>
      <description>Was expecting a sed solution too.&lt;BR /&gt;regards,&lt;BR /&gt;U.SivaKumar</description>
      <pubDate>Wed, 14 Aug 2002 03:11:24 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/script/m-p/2784803#M78150</guid>
      <dc:creator>U.SivaKumar_2</dc:creator>
      <dc:date>2002-08-14T03:11:24Z</dc:date>
    </item>
  </channel>
</rss>

