[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Bug-ed] inserting a newline after a word in a line
From: |
Duke Normandin |
Subject: |
Re: [Bug-ed] inserting a newline after a word in a line |
Date: |
Fri, 19 Mar 2010 22:23:11 -0600 (MDT) |
User-agent: |
Alpine 2.01 (OSX 1266 2009-07-14) |
On Fri, 19 Mar 2010, John Cowan wrote:
> Duke Normandin scripsit:
>
> > I entered a bunch of text, but failed to realize that I needed to
> > entered a newline in order to produce a newline. So what I have now,
> > is one huge line. I want to break it up into various lines. I'm aware
> > of the substitution command, like:
> >
> > s/break_here/break_here\n/p
> >
> > but the "\n" doesn't work in ed. Is there a way to do this?
>
> Use a literal newline, like this:
>
> s/break_here/break_here
> /p
Didn't work for me. ;( When I entered the "return key" for a literal
newline, ed thought I was done, and displayed the entire "long" line
unchanged. I never did get as far as entering the /p.
I'm on an MacOS X box, using standard (I hope) ed/red editor.
--
duke