An open API service indexing awesome lists of open source software.

https://github.com/noamfav/nvim-config

Personal neovim config, modern features and configuration near IDE level. Build with Lazy and mason
https://github.com/noamfav/nvim-config

config lazy lua mason neovim neovim-plugin

Last synced: 6 months ago
JSON representation

Personal neovim config, modern features and configuration near IDE level. Build with Lazy and mason

Awesome Lists containing this project

README

          

# 🚀 Neovim Configuration

[![Neovim](https://img.shields.io/badge/NeoVim-%2357A143.svg?&style=for-the-badge&logo=neovim&logoColor=white)](https://neovim.io/)
[![Lua](https://img.shields.io/badge/Lua-2C2D72?style=for-the-badge&logo=lua&logoColor=white)](https://www.lua.org/)
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg?style=for-the-badge)](https://opensource.org/licenses/MIT)

**A powerful, feature-rich Neovim setup for modern development**

---

## 📚 Overview

This repository contains a comprehensive Neovim configuration optimized for development with rich features including LSP support, intelligent code completion, Git integration, and much more. The setup leverages `lazy.nvim` for efficient plugin management and `mason.nvim` for handling language servers.

✨ Key highlights

- **Modern plugin manager** with lazy-loading for fast startup
- **Intelligent code completion** with LSP integration
- **AI-powered assistance** via Copilot and ChatGPT integration
- **Beautiful UI** with customizable themes and status line
- **Git integration** for seamless version control workflow
- **Enhanced productivity** with quick navigation and search
- **Specialized language support** for diverse programming needs

---

## 🌟 Features

🧩 Plugin Management

- **Lazy Loading**: Uses `lazy.nvim` to efficiently load plugins only when required
- **Performance Optimization**: Minimizes startup time and resource usage
- **Module Organization**: Clean, modular configuration structure

🧠 LSP and Autocompletion

- **LSP Support**: Powered by `mason.nvim` and `nvim-lspconfig`
- **Intelligent Autocompletion**: Using `nvim-cmp` with multiple sources
- **Snippet Integration**: Enhanced with `LuaSnip` for code snippets
- **AI Coding Assistants**:
- `copilot.vim` for AI-powered code suggestions
- `ChatGPT.nvim` for AI-driven assistance

🔍 Code Navigation and Search

- **Fuzzy Finding**: `telescope.nvim` for quick file and symbol search
- **File Explorer**: `nvim-tree.lua` with file icons and navigation
- **Semantic Highlighting**: Enhanced code readability with `semantic-highlight.vim`
- **Tag Navigation**: Code structure browsing with `tagbar`
- **Fast File Switching**: Quick file marking and jumping with `harpoon`

📝 Git Integration

- **Inline Blame**: See commit information with `git-blame.nvim`
- **Change Visualization**: View diffs with `diffview.nvim`
- **Conflict Resolution**: Handle merge conflicts via `git-conflict.nvim`
- **Git UI**: Full Git experience with `lazygit.nvim` integration
- **Change Indicators**: Track changes in the gutter with `gitsigns.nvim`

⚡ Editing and Productivity

- **Smart Commenting**: Toggle comments easily with `Comment.nvim`
- **Auto-saving**: Automatic file saving with `auto-save.nvim`
- **Bracket Pairing**: Auto-close brackets with `nvim-autopairs`
- **Code Structure**: Visual indentation with `indent-blankline.nvim`
- **Task Management**: Highlighted TODOs with `todo-comments.nvim`
- **Performance**: Faster startup with `impatient.nvim`

🎨 UI and Aesthetics

- **Status Line**: Customizable interface with `lualine.nvim`
- **File Icons**: Enhanced visuals with `nvim-web-devicons`
- **Theme Selection**: Multiple themes including `onedark.nvim`, `sonokai`, and `2077.nvim`
- **Welcome Screen**: Custom dashboard with `dashboard-nvim`
- **Notifications**: Stylish alerts with `nvim-notify`

💻 Terminal Integration

- **Integrated Terminal**: Toggle-able terminal with `toggleterm.nvim`
- **Visual Terminal**: Beautifully integrated within the editor

🔧 Specialized Language Support

- **LaTeX**: Rich typesetting with `vimtex`
- **MATLAB**: Syntax and navigation via `vim-matlab`
- **JSX/React**: Enhanced highlighting with `vim-jsx-pretty`
- **Gradle**: Build automation support with `vim-gradle`

---

## 🔧 Installation

### Prerequisites

Neovim Requirements

Ensure you have **Neovim v0.5+** installed:

| OS | Installation Command |
|----|---------------------|
| **macOS** | `brew install neovim` |
| **Ubuntu** | `sudo apt update && sudo apt install neovim` |
| **Windows** | Download from [Neovim Releases](https://github.com/neovim/neovim/releases) |

Package Managers

- **Homebrew (macOS/Linux):**
```bash
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
```

- **APT (Ubuntu/Debian):**
Most packages can be installed via the default package manager.

Language Dependencies

Language
macOS
Ubuntu
Windows

Java
brew install java
sudo apt install default-jdk
Install from AdoptOpenJDK

Python
brew install python
sudo apt install python3
Install from python.org

Node.js
brew install node
sudo apt install nodejs npm
Install from nodejs.org

Go
brew install go
sudo apt install golang
Install from golang.org

Rust
brew install rust
sudo apt install rustc
Install from rust-lang.org

Ruby
brew install ruby
sudo apt install ruby-full
Install from ruby-lang.org

LaTeX
brew install --cask mactex
sudo apt install texlive-full
Install from miktex.org

Additional Tools

Tool
macOS
Ubuntu
Windows

Git
brew install git
sudo apt install git
Install from git-scm.com

LazyGit
brew install lazygit
sudo add-apt-repository ppa:lazygit-team/release
sudo apt update
sudo apt install lazygit

Download from LazyGit Releases

Ripgrep
brew install ripgrep
sudo apt install ripgrep
Download from Ripgrep Releases

Docker
brew install --cask docker
sudo apt install docker.io
Install Docker Desktop

Language Server Setup

Language
Installation

Python
pip install 'python-lsp-server[all]'

JavaScript/TypeScript
npm install -g typescript typescript-language-server

Go
go install golang.org/x/tools/gopls@latest

Rust
brew install rust-analyzer (macOS)
sudo apt install rust-analyzer (Ubuntu)

Most language servers can be installed directly through Mason (`:Mason`) once Neovim is configured.

### Configuration Installation

Setup Steps

1. **Clone the Repository**

```bash
git clone https://github.com/NoamFav/Nvim-config ~/.config/nvim
```

2. **Open Neovim and Install Plugins**

```vim
:Lazy install
```

3. **Verify Language Server Installation**

Run `:Mason` in Neovim to install or update language servers.

---

## ⌨️ Key Mappings

General Navigation

| Mapping | Action |
|---------|--------|
| `bn` | Next buffer |
| `bp` | Previous buffer |
| `bd` | Delete buffer |
| `tn` | Next tab |
| `tp` | Previous tab |
| `to` | Open new tab |
| `tc` | Close tab |
| `pd` | Page down |
| `pu` | Page up |

File and Code Navigation

| Mapping | Action |
|---------|--------|
| `ff` | Find files |
| `fe` | File browser |
| `fd` | Find diagnostics |
| `gf` | Git files |
| `gs` | Grep current word |
| `` | Toggle file explorer |
| `r` | Refresh file explorer |
| `n` | Find current file |
| `tt` | Toggle tag browser |
| `tf` | Focus tag browser |

LSP and Diagnostics

| Mapping | Action |
|---------|--------|
| `dn` | Next diagnostic |
| `dp` | Previous diagnostic |
| `df` | Format buffer |
| `rn` | Rename symbol |
| `K` | Show documentation |
| `ca` | Code action menu |
| `cl` | Toggle diagnostics |
| `xx` | Toggle diagnostics view |
| `xX` | Buffer diagnostics |
| `cs` | Toggle symbols |
| `cc` | Close diagnostics |

Git Operations

| Mapping | Action |
|---------|--------|
| `lg` | Open LazyGit |
| `qf` | Show quickfix |
| `xQ` | Toggle quickfix |

Maven Commands

| Mapping | Action |
|---------|--------|
| `mm` | mvn clean install |
| `mp` | mvn clean package |
| `mc` | mvn clean |
| `mt` | mvn test |
| `me` | mvn exec:exec |
| `mf` | mvn javafx:run |
| `mj` | mvn javadoc:javadoc |

AI and Copilot

| Mapping | Action |
|---------|--------|
| `` | Accept Copilot suggestion |
| `` | Dismiss Copilot suggestion |
| `ai` | Open ChatGPT window |
| `ac` | Complete code with ChatGPT |
| `ae` | Edit with ChatGPT instruction |

Terminal and Miscellaneous

| Mapping | Action |
|---------|--------|
| `` | Toggle terminal |
| `s` | Toggle semantic highlighting |
| `` | Toggle focus on file explorer |
| `fb` | Find buffers |
| `fh` | Find help |
| `fg` | Live grep text |
| `rm` | Run MATLAB script |

---

## 🧩 Plugin Gallery

Core Plugins

| Plugin | Description |
|--------|-------------|
| [lazy.nvim](https://github.com/folke/lazy.nvim) | Modern plugin manager |
| [nvim-lspconfig](https://github.com/neovim/nvim-lspconfig) | Configurations for built-in LSP client |
| [nvim-cmp](https://github.com/hrsh7th/nvim-cmp) | Completion engine |
| [mason.nvim](https://github.com/williamboman/mason.nvim) | Package manager for LSP servers |
| [telescope.nvim](https://github.com/nvim-telescope/telescope.nvim) | Fuzzy finder and search tool |
| [nvim-tree.lua](https://github.com/nvim-tree/nvim-tree.lua) | File explorer |
| [nvim-treesitter](https://github.com/nvim-treesitter/nvim-treesitter) | Advanced syntax highlighting |

UI and Appearance

| Plugin | Description |
|--------|-------------|
| [lualine.nvim](https://github.com/nvim-lualine/lualine.nvim) | Status line |
| [nvim-web-devicons](https://github.com/nvim-tree/nvim-web-devicons) | File icons |
| [onedark.nvim](https://github.com/navarasu/onedark.nvim) | OneDark theme |
| [sonokai](https://github.com/sainnhe/sonokai) | Sonokai theme |
| [2077.nvim](https://github.com/hemangsk/2077.nvim) | Cyberpunk theme |
| [dashboard-nvim](https://github.com/glepnir/dashboard-nvim) | Start screen |
| [nvim-notify](https://github.com/rcarriga/nvim-notify) | Notifications |
| [indent-blankline.nvim](https://github.com/lukas-reineke/indent-blankline.nvim) | Indent guides |
| [nvim-ts-rainbow](https://github.com/p00f/nvim-ts-rainbow) | Rainbow parentheses |

Git Integration

| Plugin | Description |
|--------|-------------|
| [git-blame.nvim](https://github.com/f-person/git-blame.nvim) | Git blame information |
| [diffview.nvim](https://github.com/sindrets/diffview.nvim) | Git diff viewer |
| [git-conflict.nvim](https://github.com/akinsho/git-conflict.nvim) | Conflict resolution |
| [lazygit.nvim](https://github.com/kdheepak/lazygit.nvim) | LazyGit integration |
| [gitsigns.nvim](https://github.com/lewis6991/gitsigns.nvim) | Git status indicators |

Code Enhancement

| Plugin | Description |
|--------|-------------|
| [LuaSnip](https://github.com/L3MON4D3/LuaSnip) | Snippet engine |
| [nvim-autopairs](https://github.com/windwp/nvim-autopairs) | Auto-close brackets |
| [Comment.nvim](https://github.com/numToStr/Comment.nvim) | Code commenting |
| [auto-save.nvim](https://github.com/Pocco81/auto-save.nvim) | Auto-save files |
| [formatter.nvim](https://github.com/mhartington/formatter.nvim) | Code formatting |
| [todo-comments.nvim](https://github.com/folke/todo-comments.nvim) | Highlight TODOs |
| [tagbar](https://github.com/preservim/tagbar) | Code structure view |
| [semantic-highlight.vim](https://github.com/thiagoalessio/semantic-highlight.vim) | Semantic highlighting |
| [which-key.nvim](https://github.com/folke/which-key.nvim) | Keybinding hints |

Language Specific

| Plugin | Description |
|--------|-------------|
| [vimtex](https://github.com/lervag/vimtex) | LaTeX support |
| [vim-matlab](https://github.com/swlkr/vim-matlab) | MATLAB support |
| [vim-jsx-pretty](https://github.com/MaxMEllon/vim-jsx-pretty) | JSX/React syntax |
| [vim-gradle](https://github.com/tfnico/vim-gradle) | Gradle support |

AI and Assistance

| Plugin | Description |
|--------|-------------|
| [copilot.vim](https://github.com/github/copilot.vim) | GitHub Copilot integration |
| [ChatGPT.nvim](https://github.com/jackMort/ChatGPT.nvim) | ChatGPT integration |

Completion Sources

| Plugin | Description |
|--------|-------------|
| [cmp-buffer](https://github.com/hrsh7th/cmp-buffer) | Buffer words |
| [cmp-cmdline](https://github.com/hrsh7th/cmp-cmdline) | Command line |
| [cmp-nvim-lsp](https://github.com/hrsh7th/cmp-nvim-lsp) | LSP source |
| [cmp-path](https://github.com/hrsh7th/cmp-path) | File paths |
| [cmp-vsnip](https://github.com/hrsh7th/cmp-vsnip) | Snippet integration |

Utility Plugins

| Plugin | Description |
|--------|-------------|
| [plenary.nvim](https://github.com/nvim-lua/plenary.nvim) | Lua utilities |
| [popup.nvim](https://github.com/nvim-lua/popup.nvim) | Popup API |
| [nui.nvim](https://github.com/MunifTanjim/nui.nvim) | UI components |
| [impatient.nvim](https://github.com/lewis6991/impatient.nvim) | Startup optimization |
| [toggleterm.nvim](https://github.com/akinsho/toggleterm.nvim) | Terminal integration |
| [trouble.nvim](https://github.com/folke/trouble.nvim) | Diagnostics list |
| [harpoon](https://github.com/ThePrimeagen/harpoon) | File navigation marks |

---

## 📂 Configuration Structure

```
~/.config/nvim/
├── init.lua # Main entry point
├── lua/ # Lua configuration directory
│ ├── git.lua # Git plugin configuration
│ ├── gpt.lua # AI assistant configuration
│ ├── latex.lua # LaTeX support setup
│ ├── lualine.lua # Status line configuration
│ ├── mason.lua # LSP manager configuration
│ ├── notifications.lua # Notification system
│ ├── nvim-cmp.lua # Completion engine setup
│ ├── nvim-tree.lua # File explorer configuration
│ └── telescope.lua # Fuzzy finder setup
└── keymaps.vim # Key mappings
```

---

## 📄 License

This configuration is licensed under the [MIT License](LICENSE).

---

**Made with ❤️ by [Noam Fav](https://github.com/NoamFav)**

[⭐ Star this Repository](https://github.com/NoamFav/Nvim-config) • [🐛 Report Issue](https://github.com/NoamFav/Nvim-config/issues) • [🔄 Fork](https://github.com/NoamFav/Nvim-config/fork)