Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

help with script

Status
Not open for further replies.

anatazi

Programmer
Jun 24, 2002
33
US
Hi all,
I need to write a script that concatenate lists together, and output the resulting list. For example:
clean_list a a:b a:b:c :x: y:z
a:b:c:.:x:y:z

How do I go about that, could someone please help get me started;
Thanks
 

try this:

STRING=`echo 'a:b:b:z:q:q:Y:i' |tr ',' '\n'|sort -u|tr '\n' ','`

i know a -s option for tr, but could not get it working
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top