Hello there fellow stranger!
This is my custom PDE for Neovim! (it has been tested on Linux and Windows).
It provides the following:
and more!
If you're using this configuration with Neovim 0.6/0.6.1, you'll have to deal with the formatters outputing wrong
eol
onWindows
files (fileformat=dos
). There was an issue, which is already merge.
There is not a custom installation script (for now). To use this config follow steps:
Windows
CMD
/PowerShell
/Bash
~\AppData\Local
(C:\Users\your_user\AppData\Local)git clone https://github.com/fedepujol/nvim.git
Linux
~/.config/
git clone https://github.com/fedepujol/nvim.git
On first launch, lazy package manager will download
every plugin declared on the folder /lua/plugins
and on /lua/core/lazy.lua
file.
After this, re-open neovim. Then when you open a file, mason-lspconfig.nvim
will download the LSP's configured in the file /lua/plugins/lspconfig.lua
.
Lsp | File |
---|---|
angularls | html/typescript |
bashls | sh/bash |
css | css |
html | html |
lua_ls | lua |
marksman | markdown |
prosemd_lsp | markdown |
rust-analyzer | rust |
tsserver | typescript |
vimlsp | vim |
yamllsp | yaml |
Neovim has integrated a lot of cool features, one of them is the ability to
interact with language servers
to get some auto-completions, diagnostics and
more based on the language you're using.
To install a server you'll use the plugin mason.nvim
and mason-lspconfig.nvim
by typing:
:MasonInstall name-of-server
To view all available servers to download and managed the ones you've got:
:Mason
I’ve included several lsp’s initializations (bash, css, html, etc.) in
lua/plugins/lspconfig.lua
.
These are maintained in nvim-lspconfig
repo. There you'll find the configurations
for several servers. If you want one, just take the config and paste it on the file.
If you want more control, change the default values.
A lot of the times, you'll have something like this:
require('lspconfig').tsserver.setup({})
The setup
function already has default values,
which in most cases works out of the box. Then install the server:
:MasonInstall tsserver
And you're ready to go!
mason.nvim
takes care of installing of configure the formatters and linters.
Just type:
:Mason
And navigate to Formatters
or Linters
, select the ones you want and install them!
This repo follows the plugin structure of lazy.nvim
. If you want to know more
visit the repo.
lua/core/settings.lua
Every setting you want to change about Neovim goes in here.
Neovim related keybindings
lua/core/mappings.lua
Pluggins keybindings:
lua/core/which-key.lua
These are the plugins included: