My Neovim configuration

Published on

An important information

You need to create a user folder in your lua folder. Because this way you prevent naming collision. I discovered that because lualine won’t work if the file that contains my configuration is called lualine.lua and it’s not in the lua/user folder.

Packer and first packages install

First thing is to install Packer, without a package manager you can’t do anything

Create a file called plugins.lua with this code inside

return require('packer').startup(function(use)
    use 'wbthomason/packer.nvim'
    use {
        'neoclide/coc.nvim',
        branch = 'release'
    }
end)

I’m installing Packer itself so I can update it via Neovim. The second plugin is coc.nvim and it’s the first plugin that I want to see working.

Configuring coc.nvim, the code completion

There is a huge configuration that you can copy and paste into yours. coc doesn’t modify any key mappings so you need this configuration.

I’m using Lua so here is the right configuration.

lualine.nvim, the status line

nvim-tree, the tree view

Add a tree navigation.

bufdelete.nvim, buffers

Better management of closing buffers. No more broken windows.

bufferline.nvim, the tabs

Add a new line a the top of the screen with the buffers shown like tabs.

Comment.nvim, the comments

https://github.com/numToStr/Comment.nvim

nvim-treesitter, better syntax highlighting

https://github.com/nvim-treesitter/nvim-treesitter

Git support

filetype.nvim, optimization

https://github.com/nathom/filetype.nvim

Markdown

https://github.com/ellisonleao/glow.nvim -> preview

Manage parenthesis

https://github.com/kylechui/nvim-surround

tokyonight.nvim, the theme

Last but not least.

I want to use the theme with the most support and usage around. This theme is tokyonight.nvim.

The final result

Maybe it’s not perfect but it has been a wonderful journey until now.

NaryaVim

Thanks for reading to the end! 🎉

If you’d like to stay in touch Follow me on Twitter and Mastodon.

I'm active in many places on the internet, checkout the footer or the links page.