How to strip A NEWLINE
Stephen M. Kennedy
smk at cbnews.att.com
Sat Dec 1 08:32:38 AEST 1990
In article <1781 at seti.inria.fr>, deschamp at minos.inria.fr (Philippe Deschamp) writes:
> [sed script to remove \<new-line>]
> sed -e ': more
> /:\\$/{
> N
> s/:\\\n *:*/:/
> t more
> }'
Anybody got any ideas on how to make this script work on input of the form
one:\
two:\
three:\
oops:\
<EOF>
Currently, the N command aborts and the script produces no output on the
last iteration; I'd like it to just act as if the last \ wasn't there.
Steve Kennedy
smk at cbosgd.att.com
smk at cbnews.att.com
More information about the Comp.unix.shell
mailing list