Skip to content

Neovim Config packed with top plugins such as Telescope, Treesitter, LSPSaga, and many more

Notifications You must be signed in to change notification settings

davindj/nvim-config

Repository files navigation

NVIM Config

This is my simple nvim 0.8.0 config for my daily working.

Notes: for the background you must set your own background in your terminal emulator.

🌟 Overview

Main

  • Config for newest neovim 0.8.0
  • Use Packer as nvim plugin manager

Plugins & Features

  • Easy File Navigation with Telescope & Harpoon.
    • Find file like ctrl + p in vsc*de
    • See all commits and file changes in your git repo
    • Search manual, help, documentation.
    • Bookmark file and navigate easily with just few keystroke
  • LSP Integrated. Makes neovim IDE-ish
    • Show Diagnostic such as Warning, Hint, Error of your codebase.
    • Code Action 💡
    • Go to Variable Definition & Implementation. (with help of lspsaga)
    • Format Whole Document.
    • See document outline and navigate to each property.
    • AutoComplete. (using cmp)
    • Snippet. (using ultisnips)
    • Show Hint & Detail Parameter during Code Writing (using lsp_signature)
  • Linting with ale.
  • Better source code highlighting and context navigation with Treesitter.
  • Code Commentary with motion with Comment. (also support treesitter motion)
  • Working Git File Changes with gitsigns
    • Highlight Changes in sign column
    • Jump to changes
    • Revert changes in hunk and file scope
    • Preview changes
    • See author of code/changes (git blame)
  • Project Structure with nvim-tree. see project structure and interact with your file.
  • Customized Start Screen with startify, show your recently edited files and bookmarked files. you can also go to that file.

Other Plugins

🔧 Requirement

Here's few importants requirements to use this config perfectly.

OS Requirement

  • MacOS or ANY Linux Distros

For Windows User, I HIGHLY RECOMMEND to use WSL.

Just migrate to Mac or Linux will ya :)

Software Requirement

  • Neovim (duh). Get it on your favorite OS package manager such as brew (for MacOS), dnf, apt.
# for brew
$ brew install neovim

# to check wether proper neovim is properly installed
$ nvim --version
  • pynvim. This is used by ultisnips engine for snippet.
$ python3 -m pip install --user --upgrade pynvim
  • ripgrep. This is used by telescope for live_grep features. You can install ripgrep in your OS Package Manager.
# for brew
$ brew install ripgrep

LSP Requirement

LSP is used to make your text editor smarter and have context of your codebase, or to make your text-editor become IDE. Since LSP for each programming language is different you can install your favorite programming languages LSP.

  • TSServer. LSP for Javascript & Typescript. You'll need npm
    # Install LSP
    $ sudo npm i -g typescript typescript-language-server
    
    # Check Path & Installation
    $ typescript-language-server --version
  • GOPLS. LSP for Go. You'll need to install go.
    Make sure go/bin is accessible in $PATH
    # ~/.zshrc
    export PATH="$PATH:$HOME/go/bin"
    Install LSP
    # Install LSP
    $ go install golang.org/x/tools/gopls@latest
    
    # Check Path & Installation
    $ gopls version
  • SourceKit. LSP for Swift. For this LSP there are few ways to install it. For me the easiest way is to just install xcode, because xcode come with LSP. but you can see other installation method on their official repo. And after that make sure sourcekit-lsp is accessible in $PATH
    # ~/.zshrc
    export PATH="$PATH:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/sourcekit-lsp"

Notes: if installation succeed but you can't run that LSP, make sure that your LSP is accessible in $PATH

UI Requirement

This config use nerdfont, so you'll need to set your terminal emulator font using nerdfont and enable ligature options.

🏃‍♂️ Getting Started

After you met all the requirement and done setup. Follow this step to use my nvim config

  1. Clone / download this project anywhere
$ git clone https://github.com/davindj/nvim-config
  1. Move config to nvim configuration folder ~/.config/nvim
# make sure you backup your nvimconfig, otherwise it will be overwritten
$ mv ./nvim-config ~/.config/nvim
  1. Run neovim
$ nvim
  1. On the neovim, run this command to make sure all plugins were installed properly.
:PackerSync
  1. Done!. Enjoy my config 😜.

🎯 TODO Next

  • Mess around with Telescope
  • Create customized snippet w/ ultisnips
  • Explore Debugging Plugin
  • Explore GIT-related Plugin
  • Config markdown plugin. seriously rn I use vsc*de for create this readme.md
  • Add keymap list in this readme
  • Update Preview NVIM in this readme (tokioooo)

📒 Additional Notes

If you have some tips 👍, ideas 💡, recommendations 📝, or even BUGG 👾, feel free to contact me :). And if you find this config useful, don't forget to give a 🌟

About

Neovim Config packed with top plugins such as Telescope, Treesitter, LSPSaga, and many more

Topics

Resources

Stars

Watchers

Forks

Languages