grep into one line

Please support our Perl advertiser: Programming Forums - DaniWeb Sister Site
Reply

Join Date: May 2007
Posts: 1
Reputation: raj_repos is an unknown quantity at this point 
Solved Threads: 0
raj_repos raj_repos is offline Offline
Newbie Poster

grep into one line

 
0
  #1
May 24th, 2007
Hi
i ahve following find & grp command the command look into the file and check the pattern and output to three lines.

is it is possible this output into one line seperated with some characters

-------

find ./*temp.log* | xargs -i{} cat {} | egrep -e 'Control:' -e 'Run' |cut -c1-100

the out put of this file is


Control File: /u01/cle/dc/der/temp.ctl
Run began on Wed May 23 23:15:00 2007
Run ended on Wed May 23 23:31:20 2007


i need the out put like in one continoous line

Control File: /u01/cle/dc/der/temp.ctl , Run began on Wed May 23 23:15:00 2007 ,Run ended on Wed May 23 23:31:20 2007
Reply With Quote Quick reply to this message  
Join Date: Mar 2006
Posts: 898
Reputation: KevinADC has a spectacular aura about KevinADC has a spectacular aura about 
Solved Threads: 67
KevinADC's Avatar
KevinADC KevinADC is offline Offline
Practically a Posting Shark

Re: grep into one line

 
0
  #2
May 24th, 2007
I think you have posted in the wrong forum, this is the perl forum. Post your question in the appropriate shell scripting forum if there is one.
Last edited by KevinADC; May 24th, 2007 at 4:41 am.
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:



Similar Threads
Other Threads in the Perl Forum
Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC