Posts for: #Nvim

Nvim Search

Nvim Search

Some quick tips on searching in nvim.

To search for a word in the current file:

:/your_word

Uses regex to search for the word in the current file. Use ’n’ to go to the next instance of the word, and ‘N’ to go to the previous.

To search for the word selected in visual mode, press * or #. This will search for the word under the cursor.

Now to find and replace, the %s command is used. For example:

Read more →

nvim Markdown

nvim Markdown

Spell checking

To enable spell checking in vim, use the command set spell. This will highlight misspelled words in your markdown files.

To enable spell checking:

:set spell
:set spelllang=en_us

Spelling suggestions can be accessed with z=. This will open a window with suggestions for the misspelled word.

If you want to add a word to your dictionary, use the command zg.

Or to manually add a word to your dictionary:

:spellgood YOUR_WORD

Line wrapping

Set your line width to 80 characters. This is a good width for readability and makes it easier to read your markdown files on different devices.

Read more →