Sunday, June 3, 2012

Re: Repeat gq from : command line?

On 06/03/12 19:20, howard Schwartz wrote:
> while line(".") <= line("$")
> :/^[[:lower:][:punct:]]/\{3,} normal gq /^\L^M

While I haven't actually tested your stuff, a couple items stand out.

1) the 2nd "/" ends the search, but it looks like you have a "repeat
3+ times" token outside that. I suspect you want

:/^[[:lower:][:punct:]]\{3,}/ norm...

2) the space after "gq" seems particularly suspect. At a minimum, I
think you mean to write

normal gq/^\L^M

(where I presume you're entering "^M" as control-V, control+M).


The infinite looping is likely a result of not moving the cursor
combined with not modifying the line as you intend.

-tim


--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

No comments:

Post a Comment