On Thursday, Mar 31, 2005, at 16:13 US/Central, Ed Howland wrote:
$ echo -e 'a b\nc d\ne f\n' | xargs | tr ' ' ','
a,b,c,d,e,f

Cool. I didn't even realize xargs could be use without a command. So by default it echos/prints the arguments. BTW, we can shave off two more characters:


$ echo -e 'a b\nc d\ne f\n' | xargs | tr ' ' ,
a,b,c,d,e,f

What would be really nice is something like this:

$ echo -e 'a b\nc d\ne f\n' | xargs --ofs=,
a,b,c,d,e,f

but I don't see anything in the man page of xargs that enables that.

Regards,
- Robert
http://www.cwelug.org/downloads
Help others get OpenSource software.  Distribute FLOSS
for Windows, Linux, *BSD, and MacOS X with BitTorrent

_______________________________________________
CWE-LUG mailing list
http://www.cwelug.org/ [email protected]
http://lists.firepipe.net/listinfo/cwe-lug

Reply via email to