Wednesday, June 2, 2010

Re: Search for several words in each line with vim?

Hi rewar!

On Mi, 02 Jun 2010, rewar wrote:

> thanks for the prompt reply! i really appreciate it. it worked
> perfectly, however it didnt require the "$" sign?

Yes that is true. $ means line end. Since there was a .* beofre it, it
will automatically match until the end of the line.

> also, how would u do it so that its not case sensitive? so it will
> return a line with CaTs and DOGS

Add \c in the pattern. You should really lern to use regular
expressions. Take a look at :h pattern.txt and :h usr_27.txt
> further, how do you become better at using such an editor as vim? I
> only know some basic stuff for c programming and when i need to do
> something like search/replace, i just google it. is there a good guide
> to start with? I mean that statement u wrote just then was quite
> complex for me to even understand lol

Read the help. When finished, read it again ;)

This is really good and basically explains everything. Of course you can
also hang up here and learn from others. That was how I did it ;)

So take a look at :h help.txt and :h usr_toc.txt

Oh and the wiki (http://vim.wikia.com) is probably also worth a look.

[Fullquote snipped]
please don't top quote.

regards,
Christian
--
Der donnernde Gott, der zürnende Gott, der rächende Gott. Was für ein
Choleriker.
-- Heinrich Wiesner

--
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: