<?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: shell script in Operating System - Linux</title>
    <link>https://community.hpe.com/t5/operating-system-linux/shell-script/m-p/3823575#M100385</link>
    <description>Hi,&lt;BR /&gt;&lt;BR /&gt;so you need something more awk:&lt;BR /&gt;awk 'last {printf last","};{last=$0};END {print last}' filename&lt;BR /&gt;&lt;BR /&gt;mfG Peter</description>
    <pubDate>Fri, 14 Jul 2006 04:04:55 GMT</pubDate>
    <dc:creator>Peter Nikitka</dc:creator>
    <dc:date>2006-07-14T04:04:55Z</dc:date>
    <item>
      <title>shell script</title>
      <link>https://community.hpe.com/t5/operating-system-linux/shell-script/m-p/3823570#M100380</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;I need to compile a mailing list from multiple line to one single line&lt;BR /&gt;&lt;BR /&gt;From multiple line&lt;BR /&gt;abc@mydomain.com&lt;BR /&gt;bcd@mydomain.com&lt;BR /&gt;efe@mydomain.com&lt;BR /&gt;&lt;BR /&gt;to single line&lt;BR /&gt;abc@mydomain.com,bcd@mydomain.com,efe@mydomain.com&lt;BR /&gt;&lt;BR /&gt;Of course I can write the output to a file and do a while loop.  Is there anyway I can do it in one single line of command</description>
      <pubDate>Fri, 14 Jul 2006 01:20:45 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/shell-script/m-p/3823570#M100380</guid>
      <dc:creator>wanaka_1</dc:creator>
      <dc:date>2006-07-14T01:20:45Z</dc:date>
    </item>
    <item>
      <title>Re: shell script</title>
      <link>https://community.hpe.com/t5/operating-system-linux/shell-script/m-p/3823571#M100381</link>
      <description>tr '\n' ',' &amp;lt; your_file</description>
      <pubDate>Fri, 14 Jul 2006 01:43:46 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/shell-script/m-p/3823571#M100381</guid>
      <dc:creator>RAC_1</dc:creator>
      <dc:date>2006-07-14T01:43:46Z</dc:date>
    </item>
    <item>
      <title>Re: shell script</title>
      <link>https://community.hpe.com/t5/operating-system-linux/shell-script/m-p/3823572#M100382</link>
      <description>hi;&lt;BR /&gt;&lt;BR /&gt;awk '{printf "%s,",$0}' file_name &amp;gt; out_file</description>
      <pubDate>Fri, 14 Jul 2006 01:45:23 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/shell-script/m-p/3823572#M100382</guid>
      <dc:creator>Kenan Erdey</dc:creator>
      <dc:date>2006-07-14T01:45:23Z</dc:date>
    </item>
    <item>
      <title>Re: shell script</title>
      <link>https://community.hpe.com/t5/operating-system-linux/shell-script/m-p/3823573#M100383</link>
      <description>The method is ok but the kena script will print the last one end with ','.</description>
      <pubDate>Fri, 14 Jul 2006 01:50:36 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/shell-script/m-p/3823573#M100383</guid>
      <dc:creator>wanaka_1</dc:creator>
      <dc:date>2006-07-14T01:50:36Z</dc:date>
    </item>
    <item>
      <title>Re: shell script</title>
      <link>https://community.hpe.com/t5/operating-system-linux/shell-script/m-p/3823574#M100384</link>
      <description>Hi,&lt;BR /&gt;how about:&lt;BR /&gt; paste -s -d"," filename | sed "$ s/,$//"</description>
      <pubDate>Fri, 14 Jul 2006 03:28:00 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/shell-script/m-p/3823574#M100384</guid>
      <dc:creator>Peter Godron</dc:creator>
      <dc:date>2006-07-14T03:28:00Z</dc:date>
    </item>
    <item>
      <title>Re: shell script</title>
      <link>https://community.hpe.com/t5/operating-system-linux/shell-script/m-p/3823575#M100385</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;so you need something more awk:&lt;BR /&gt;awk 'last {printf last","};{last=$0};END {print last}' filename&lt;BR /&gt;&lt;BR /&gt;mfG Peter</description>
      <pubDate>Fri, 14 Jul 2006 04:04:55 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/shell-script/m-p/3823575#M100385</guid>
      <dc:creator>Peter Nikitka</dc:creator>
      <dc:date>2006-07-14T04:04:55Z</dc:date>
    </item>
    <item>
      <title>Re: shell script</title>
      <link>https://community.hpe.com/t5/operating-system-linux/shell-script/m-p/3823576#M100386</link>
      <description>Soooo many ways to do that&lt;BR /&gt;&lt;BR /&gt;These two will not add a trailing comma&lt;BR /&gt;&lt;BR /&gt;# perl -nle'push@x,$_}END{chomp@x;print join","@x' file&lt;BR /&gt;&lt;BR /&gt;# perl -le'BEGIN{$/=undef}chomp(@x=&amp;lt;&amp;gt;);print join",",@x' file&lt;BR /&gt;&lt;BR /&gt;The good tr example and this short command will&lt;BR /&gt;&lt;BR /&gt;# perl -pe's/\n/,/' file&lt;BR /&gt;&lt;BR /&gt;Enjoy, Have FUN! H.Merijn</description>
      <pubDate>Fri, 14 Jul 2006 04:23:20 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/shell-script/m-p/3823576#M100386</guid>
      <dc:creator>H.Merijn Brand (procura</dc:creator>
      <dc:date>2006-07-14T04:23:20Z</dc:date>
    </item>
    <item>
      <title>Re: shell script</title>
      <link>https://community.hpe.com/t5/operating-system-linux/shell-script/m-p/3823577#M100387</link>
      <description>Hi,&lt;BR /&gt;please also read:&lt;BR /&gt;&lt;A href="http://forums1.itrc.hp.com/service/forums/helptips.do?#28" target="_blank"&gt;http://forums1.itrc.hp.com/service/forums/helptips.do?#28&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Fri, 14 Jul 2006 05:45:40 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/shell-script/m-p/3823577#M100387</guid>
      <dc:creator>Peter Godron</dc:creator>
      <dc:date>2006-07-14T05:45:40Z</dc:date>
    </item>
  </channel>
</rss>

