realphongha / nvim-configs

My configurations for Neovim

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

nvim-configs

My neovim configs.
Tested with nvim 0.9.x on MacOS, Linux and Windows.

How to install?

Install Neovim first.
Then simply clone this repo directly into your Neovim configs directory:

For Linux/Mac OS

# removes all your previous nvim configs first!
rm -rf ~/.config/nvim
# removes all your previous nvim data
# rm -rf ~/.local/share/nvim
git clone https://github.com/realphongha/nvim-configs.git ~/.config/nvim

For Windows (on Powershell)

# removes all your previous nvim configs first!
Remove-Item -Path "~/AppData/Local/nvim" -Recurse -Force
# removes all your previous nvim data 
# Remove-Item -Path "~/AppData/Local/nvim-data" -Recurse -Force
cd ~/AppData/Local/
git clone https://github.com/realphongha/nvim-configs.git nvim

Done!

Plugin manager

lazy.nvim

Lazy load:

  • :LspStart to load nvim-lspconfig (pls run it once after installing this config to initialize LSP servers)
  • :Git to load vim-fugitive
  • :Codeium to load codeium.vim (and :Codeium Auth to enter your token)

Add your personal configs and plugins

Create lua/my_configs.lua for your personal configs or
lua/my_plugins.lua for your personal plugins (in lazy.nvim format).

Install LSP servers:

Some LSP servers are already integrated in configs but you need to install them first.

You can use mason.nvim (already installed) or manually install (below):

For jedi

pip install jedi-language-server

For pyright:

npm i -g pyright

For tsserver

npm install -g typescript typescript-language-server

For rust-analyzer

Install

For ccls

Install

For clangd

Install

For cmake-language-server

Install

For rust-analyzer

Install

For lua-language-server

Install

To add other LSP supports:

  • Install LSP servers (manually or using mason.nvim)
  • Add LSP configs for neovim in lua/plugins/coding.lua, mason-lspconfig->config section.
  • Add lazy load condition to nvim-lspconfig->ft section in lua/plugins/coding.lua

Acknowledgements

This repo is directly inspired by vimrc, ThePrimeagen video and Learn Vimscript the Hard Way.

Plugins included:

Colorschemes included:

Others

  • the_silver_searcher is supported as 'grep' command (but you need to install it on your system first)
  • ripgrep should be installed first if you want to use telescope livegrep
  • Patched fonts should be installed for nvim-tree

Small notes

  • Use :lua SeeWaifu() or :lua SeeWaifu("colorscheme-name") to make your background transparent and see your waifu in the terminal :D
  • Simple Neovim Qt configs is also supported (in ginit.vim). Neovim Qt must be installed first. You can run misc/add_nvimqt_to_context_menu_windows.reg to add Neovim Qt to context menu (only for Windows) (stolen from here) :D
  • Check out my minimal configs for tmux if you want to use it with nvim

About

My configurations for Neovim


Languages

Language:Lua 98.3%Language:Vim Script 1.7%