<?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: reading and displaying log using csh in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/reading-and-displaying-log-using-csh/m-p/4892966#M701002</link>
    <description>example&lt;BR /&gt;&lt;BR /&gt;#!/bin/csh &lt;BR /&gt; &lt;BR /&gt;foreach line (`cat &lt;FILE&gt;`) &lt;BR /&gt; echo $line &lt;BR /&gt;end &lt;BR /&gt;&lt;/FILE&gt;</description>
    <pubDate>Wed, 30 Mar 2005 05:35:50 GMT</pubDate>
    <dc:creator>Henry Chua</dc:creator>
    <dc:date>2005-03-30T05:35:50Z</dc:date>
    <item>
      <title>reading and displaying log using csh</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/reading-and-displaying-log-using-csh/m-p/4892957#M700993</link>
      <description>Hi Guys,&lt;BR /&gt;&lt;BR /&gt; I used to read lines from a LOGfile using ksh "&lt;BR /&gt;#!/usr/bin/ksh&lt;BR /&gt;while read line&lt;BR /&gt;do&lt;BR /&gt;  echo "$line"&lt;BR /&gt;&lt;BR /&gt;done &amp;lt; $LOGFILE&lt;BR /&gt;&lt;BR /&gt;but when try using csh, it gives me error "&lt;BR /&gt;while: expression syntax".. does this means it doesnt work for csh?.. is there an alternative script I can use to produce the same thing?&lt;BR /&gt;&lt;BR /&gt;regards&lt;BR /&gt;Henry&lt;BR /&gt;</description>
      <pubDate>Mon, 28 Mar 2005 02:32:05 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/reading-and-displaying-log-using-csh/m-p/4892957#M700993</guid>
      <dc:creator>Henry Chua</dc:creator>
      <dc:date>2005-03-28T02:32:05Z</dc:date>
    </item>
    <item>
      <title>Re: reading and displaying log using csh</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/reading-and-displaying-log-using-csh/m-p/4892958#M700994</link>
      <description>Shell script syntax can be different from one shell to&lt;BR /&gt;another and, as far as I remember, syntax for "while" &lt;BR /&gt;loop in csh is different than that in ksh. (I don't think&lt;BR /&gt;there is a "do" after "while" in csh). You should&lt;BR /&gt;really take a look at csh(1) manpage.&lt;BR /&gt;&lt;BR /&gt;- Biswajit&lt;BR /&gt;</description>
      <pubDate>Mon, 28 Mar 2005 03:03:29 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/reading-and-displaying-log-using-csh/m-p/4892958#M700994</guid>
      <dc:creator>Biswajit Tripathy</dc:creator>
      <dc:date>2005-03-28T03:03:29Z</dc:date>
    </item>
    <item>
      <title>Re: reading and displaying log using csh</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/reading-and-displaying-log-using-csh/m-p/4892959#M700995</link>
      <description>Is there a way to use csh to read line by  line of a logfile? possible?</description>
      <pubDate>Mon, 28 Mar 2005 19:46:49 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/reading-and-displaying-log-using-csh/m-p/4892959#M700995</guid>
      <dc:creator>Henry Chua</dc:creator>
      <dc:date>2005-03-28T19:46:49Z</dc:date>
    </item>
    <item>
      <title>Re: reading and displaying log using csh</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/reading-and-displaying-log-using-csh/m-p/4892960#M700996</link>
      <description>Ofcourse it should be possible, but I can't help you&lt;BR /&gt;there (as last time I used csh was atleast 10 &lt;BR /&gt;years back :-).&lt;BR /&gt;&lt;BR /&gt;But I fail to understand why are you trying to write &lt;BR /&gt;this in csh. "ksh" and "sh" are probably the most&lt;BR /&gt;popular shells in unix right now and I personally &lt;BR /&gt;would not spend any time learning csh. But, ofcourse, &lt;BR /&gt;you might have your compelling reason for this. In&lt;BR /&gt;that case, someone else in this forum should be&lt;BR /&gt;able to help you.&lt;BR /&gt;&lt;BR /&gt;- Biswajit&lt;BR /&gt;</description>
      <pubDate>Mon, 28 Mar 2005 20:25:13 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/reading-and-displaying-log-using-csh/m-p/4892960#M700996</guid>
      <dc:creator>Biswajit Tripathy</dc:creator>
      <dc:date>2005-03-28T20:25:13Z</dc:date>
    </item>
    <item>
      <title>Re: reading and displaying log using csh</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/reading-and-displaying-log-using-csh/m-p/4892961#M700997</link>
      <description>Henry.&lt;BR /&gt;I have no time to check correct systax for U.&lt;BR /&gt;But you can read shell userguide at&lt;BR /&gt;&lt;A href="http://docs.hp.com/en/B2355-90046/index.html" target="_blank"&gt;http://docs.hp.com/en/B2355-90046/index.html&lt;/A&gt;&lt;BR /&gt;HTH&lt;BR /&gt;tienna</description>
      <pubDate>Mon, 28 Mar 2005 21:19:52 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/reading-and-displaying-log-using-csh/m-p/4892961#M700997</guid>
      <dc:creator>Nguyen Anh Tien</dc:creator>
      <dc:date>2005-03-28T21:19:52Z</dc:date>
    </item>
    <item>
      <title>Re: reading and displaying log using csh</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/reading-and-displaying-log-using-csh/m-p/4892962#M700998</link>
      <description>The similarity between csh and any POSIX shell such as ksh, HP-UX sh, or even bash is about the same as the compatibility between German and French languages. In ksh, the words: while do done are shell keywords and read is a shell built-in. There is no reason to expect csh to recognize these words or process them the same way. The man page for csh explains these in detail.&lt;BR /&gt; &lt;BR /&gt;Now the question: why use a very limited and incompatible shell when your csh users can run the exact same script? The first line (#!/usr/bin/ksh) tells the csh shell to use a different interpreter. This is why a csh, ksh or any other Unix shell user can run a perl script or any other interpreter without changing the current shell. As long as your scripts start with #!/usr/bin.... then you can write your scripts in any shell language that's available on your system.&lt;BR /&gt; &lt;BR /&gt;This link may be helpful: &lt;A href="http://www.maths.leeds.ac.uk/~read/csh.html" target="_blank"&gt;http://www.maths.leeds.ac.uk/~read/csh.html&lt;/A&gt;&lt;BR /&gt; &lt;BR /&gt;Note that references to the Bourne shell should be replaced with "POSIX shells including ksh, HP-UX sh, bash, etc)</description>
      <pubDate>Mon, 28 Mar 2005 21:47:00 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/reading-and-displaying-log-using-csh/m-p/4892962#M700998</guid>
      <dc:creator>Bill Hassell</dc:creator>
      <dc:date>2005-03-28T21:47:00Z</dc:date>
    </item>
    <item>
      <title>Re: reading and displaying log using csh</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/reading-and-displaying-log-using-csh/m-p/4892963#M700999</link>
      <description>Hi Guys, thanks for the inputs.. i have gone thru the information u provided.. I am just wondering if u have a sample script for csh to read a log line by line.. I am really new to csh, and for some compelling reason, I am only alow to use C shell script to complete this task.. Apparently there really isnt much info on csh anywhere... &lt;BR /&gt;&lt;BR /&gt;thanks!&lt;BR /&gt;Henry</description>
      <pubDate>Mon, 28 Mar 2005 22:26:32 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/reading-and-displaying-log-using-csh/m-p/4892963#M700999</guid>
      <dc:creator>Henry Chua</dc:creator>
      <dc:date>2005-03-28T22:26:32Z</dc:date>
    </item>
    <item>
      <title>Re: reading and displaying log using csh</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/reading-and-displaying-log-using-csh/m-p/4892964#M701000</link>
      <description>"I am really new to csh, and for some compelling reason, I am only alow to use C shell script to complete this task"&lt;BR /&gt;&lt;BR /&gt;Just say NO! :-).&lt;BR /&gt;&lt;BR /&gt;Yeah I know, easy for me to say, but seriously, for your own sanity please try to get 'them' to articulate why csh is required.&lt;BR /&gt;&lt;BR /&gt;My other 'shoot from the hip' reaction would be: for lexical work like trouncing through a log, use a lexxial tool like AWK or PERL.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&amp;gt;&amp;gt; .. Apparently there really isnt much info on csh anywhere... &lt;BR /&gt;&lt;BR /&gt;For good reason... :-).&lt;BR /&gt;&lt;BR /&gt;Good luck,&lt;BR /&gt;Hein.&lt;BR /&gt;</description>
      <pubDate>Tue, 29 Mar 2005 00:25:58 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/reading-and-displaying-log-using-csh/m-p/4892964#M701000</guid>
      <dc:creator>Hein van den Heuvel</dc:creator>
      <dc:date>2005-03-29T00:25:58Z</dc:date>
    </item>
    <item>
      <title>Re: reading and displaying log using csh</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/reading-and-displaying-log-using-csh/m-p/4892965#M701001</link>
      <description>Hi Hein ^_^&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;  What can I say..&lt;BR /&gt;&lt;BR /&gt;Well the reason being that I am not able to decipher the following in csh.. &lt;BR /&gt;&lt;BR /&gt;"alias CMD1 /usr/bin/cmd1&lt;BR /&gt;&lt;BR /&gt;set planpath = "/users/home1/plan_path"&lt;BR /&gt;set tkind = 0x103&lt;BR /&gt;alias START 'onintr -; CMD1 path $planpath \!*; CMD1 start \!* $tkind;onintr TEXIT; CMD1 init'&lt;BR /&gt;&lt;BR /&gt;TEXIT:&lt;BR /&gt;&lt;PROCEDURE&gt;&lt;BR /&gt;&lt;BR /&gt;"&lt;BR /&gt;Can it be translated to ksh, if so how??&lt;BR /&gt;&lt;BR /&gt;this is really alien to me.. &lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;thanks!!&lt;BR /&gt;&lt;/PROCEDURE&gt;</description>
      <pubDate>Tue, 29 Mar 2005 00:35:03 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/reading-and-displaying-log-using-csh/m-p/4892965#M701001</guid>
      <dc:creator>Henry Chua</dc:creator>
      <dc:date>2005-03-29T00:35:03Z</dc:date>
    </item>
    <item>
      <title>Re: reading and displaying log using csh</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/reading-and-displaying-log-using-csh/m-p/4892966#M701002</link>
      <description>example&lt;BR /&gt;&lt;BR /&gt;#!/bin/csh &lt;BR /&gt; &lt;BR /&gt;foreach line (`cat &lt;FILE&gt;`) &lt;BR /&gt; echo $line &lt;BR /&gt;end &lt;BR /&gt;&lt;/FILE&gt;</description>
      <pubDate>Wed, 30 Mar 2005 05:35:50 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/reading-and-displaying-log-using-csh/m-p/4892966#M701002</guid>
      <dc:creator>Henry Chua</dc:creator>
      <dc:date>2005-03-30T05:35:50Z</dc:date>
    </item>
  </channel>
</rss>

