----- Original Message ----
From: Greg Freemyer
On Wed, May 28, 2008 at 7:19 PM, Simon Roberts wrote:
[...snip snip...]
If anyone cares:
Out of curiosity, I tried the above. It does not work because it
finds the first occurrence of ^T on a line, not the last like I
needed.
I may need to do this more in the future, so a vi command to do this
would be useful.
-----------------------------------------------------------------------------------------------------------------------
Sorry, lazy testing :(
You need:
:%s/^v^T[^^v^T]*$//
(colon, percent, ess, slash, control-v, control-t, left bracket, CARET,
control-v, control-t, right bracket, star, dollar, slash, slash
In other words, replace the dot-star "absolutely anything" wildcard
with a _set_ (square brackets) of "anything excluding control-t" (caret control-v control-t), repeated any number of
times (star).
(Or you can set minimal closures, but I forget how to do that :)
HTH,
Cheers,
Simon
"You can tell whether a man is clever by his answers. You can tell whether a man is wise by his questions." — Naguib Mahfouz
--
To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org
For additional commands, e-mail: opensuse+help@opensuse.org