Am 23.03.2009 16:03, mathneuro schrieb:
> Hello, I was wondering if anyone had an clever (or non-clever) ways of
> deleting from the cursor to the next instance of a pattern. Perhaps
> it's easier to illustrate by example. For instance, if I have the line
> of text:
> 
> This is a line of text for an example for the <a href="http://
> www.vim.org">vim</a>.
> 
> If my cursor is at, say, the beginning and my task is to delete
> everything until the 'a' tag, I can use d11w or hold down 'x' or do a
> number of other things, but is there a way to tell vim, delete from
> here to the character '<'?
> [...]

dt< or if you want to delete the '<' too then use df<

Read :help motion.txt

But this only works for single characters. If you want to delete up to a
specific string you can use v to enter visual mode, search the string
with / and then use d.


HTH,
Dennis Benzinger

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

Reply via email to