Deleting newlines

John R. Levine johnl at esegue.segue.boston.ma.us
Fri Jan 5 14:32:15 AEST 1990


In article <990 at manta.NOSC.MIL> barajas at manta.NOSC.MIL (Albert A. Barajas) writes:
>Is there a quick and dirty way to delete newlines
>from an ascii text file?

	tr -d \\012 < input > output

you might want to get rid of carriage returns, too:

	tr -d \\012\\015 < input > output
-- 
John R. Levine, Segue Software, POB 349, Cambridge MA 02238, +1 617 864 9650
johnl at esegue.segue.boston.ma.us, {ima|lotus|spdcc}!esegue!johnl
"Now, we are all jelly doughnuts."



More information about the Comp.unix.questions mailing list