Monday, August 24, 2009

Re: Remove everything up to and including a certain word


Using search-offset you have an ability to move to the end of the match. So, if I understood correctly, it should be something like

ggd/hello word /e<CR>


On Tue, Aug 25, 2009 at 12:18 AM, drlatex <n_dattani@hotmail.com> wrote:

I was wondering if I could remove everything in a file up to AND including a
certain word within the file.

Let's say I have something like ".......hello word123"

And I want only 123 to remain.

Is there a way to delete everything up to and including the string "hello
word" ??

I know that this particular string only comes up once in the file.


--~--~---------~--~----~------------~-------~--~----~
You received this message from the "vim_use" maillist.
For more information, visit http://www.vim.org/maillist.php
-~----------~----~----~----~------~----~------~--~---

No comments: