From f2d96a3676b8014f109002f0486c44a666bbe626 Mon Sep 17 00:00:00 2001 From: Moritz Reiter Date: Tue, 2 Apr 2024 11:25:43 +0200 Subject: [PATCH] vim: add basic search commands --- vim | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/vim b/vim index c46d15e8..49b5b813 100644 --- a/vim +++ b/vim @@ -54,6 +54,12 @@ P paste before cursor dd delete a line d{motion} delete text that {motion} moves over +# Searching + +/foo search for 'foo' (`n`/`N` to go to next/previous match) +?foo search backwards for 'foo' +/foo\c search for 'foo' ignoring case + # Search and replace with the `:substitute` (aka `:s`) command :s/foo/bar/ replace the first match of 'foo' with 'bar' on the current line only