Skip to content

Zwlin98/nvim

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

Personal Neovim Configuration

A modern, well-structured Neovim configuration optimized for development productivity, featuring a clean plugin architecture and thoughtful keybindings designed for HHKB users.

โœจ Features

Core Features

  • Plugin Management: Powered by lazy.nvim with lazy loading for fast startup
  • Well-Structured Architecture: Modular configuration with clear separation of concerns
  • HHKB Optimized: Keybindings specifically designed for Happy Hacking Keyboard users
  • Modern UI: Full truecolor support with beautiful themes and smooth animations
  • Game Development Focus: Special optimizations for Lua-based game development
  • Remote Development: Built-in support for remote development workflows

Developer Experience

  • Intelligent Code Completion: Advanced completion with blink.cmp
  • Smart Navigation: Fast file and symbol navigation with fzf-lua
  • Git Integration: Comprehensive Git support with visual diff and conflict resolution
  • Syntax Highlighting: Tree-sitter powered syntax highlighting with custom queries
  • Code Folding: Intelligent folding with nvim-ufo
  • Terminal Integration: Seamless terminal workflow with smart window management

๐Ÿš€ Installation

Prerequisites

Ensure you have Neovim 0.9+ installed:

nvim --version

Quick Setup

# Backup existing configuration (if any)
mv ~/.config/nvim ~/.config/nvim.backup

# Clone this configuration
git clone https://github.com/Zwlin98/nvim.git ~/.config/nvim

# Start Neovim (plugins will be installed automatically)
nvim

Post-Installation Verification

Run the following command in Neovim to ensure everything is working correctly:

:checkhealth

๐Ÿ“ฆ Dependencies

Language Servers (Pre-configured)

The configuration includes automatic setup for the following language servers:

Code Formatters (Pre-configured)

  • stylua - Lua code formatter
  • jq - JSON processor and formatter
  • yamlfmt - YAML formatter

Optional Dependencies

For enhanced functionality, consider installing:

  • ripgrep - Fast text search (for grep functionality)
  • fd - Fast file finder (alternative to find)
  • git - Version control (for Git integrations)
  • nodejs & npm - For additional language servers

๐Ÿ—‚๏ธ Configuration Structure

~/.config/nvim/
โ”œโ”€โ”€ init.lua                 # Entry point
โ”œโ”€โ”€ lazy-lock.json          # Plugin version lock file
โ”œโ”€โ”€ after/                  # After-load configurations
โ”‚   โ””โ”€โ”€ ftplugin/          # Filetype-specific settings
โ”œโ”€โ”€ ftdetect/              # Custom filetype detection
โ”œโ”€โ”€ indent/                # Custom indentation rules
โ”œโ”€โ”€ lsp/                   # Language server configurations
โ”‚   โ”œโ”€โ”€ c.lua             # C/C++ LSP setup
โ”‚   โ”œโ”€โ”€ go.lua            # Go LSP setup
โ”‚   โ”œโ”€โ”€ lua.lua           # Lua LSP setup
โ”‚   โ””โ”€โ”€ pyright.lua       # Python LSP setup
โ”œโ”€โ”€ lua/
โ”‚   โ”œโ”€โ”€ basic.lua         # Basic Neovim settings
โ”‚   โ”œโ”€โ”€ keymaps.lua       # Global keybindings
โ”‚   โ”œโ”€โ”€ autocmds.lua      # Auto commands
โ”‚   โ”œโ”€โ”€ lsp.lua           # LSP configuration
โ”‚   โ”œโ”€โ”€ rikka.lua         # Custom utility functions
โ”‚   โ””โ”€โ”€ plugins/          # Plugin configurations
โ”‚       โ”œโ”€โ”€ common/       # General purpose plugins
โ”‚       โ”œโ”€โ”€ git/          # Git-related plugins
โ”‚       โ”œโ”€โ”€ theme/        # Color schemes and themes
โ”‚       โ”œโ”€โ”€ treesitter/   # Syntax highlighting
โ”‚       โ””โ”€โ”€ ui/           # User interface plugins
โ””โ”€โ”€ syntax/               # Custom syntax files

โŒจ๏ธ Key Bindings

Leader Key

  • Space - Primary leader key

File Navigation

  • <M-e> - Find files with fuzzy search
  • <M-r> - Switch between buffers
  • <M-t> - Navigate tabs
  • <M-p> - FzfLua builtin commands
  • gf - Go to file under cursor

Search & Replace

  • <M-f> - Live grep in project
  • <M-g> - Grep word under cursor
  • <M-s> - Search current buffer lines
  • ? - Search word in current buffer

Window Management

  • <M-c> - Close current window
  • <M-x> - Close current tab

Code Navigation

  • <M-z> - Jump list navigation
  • gq - Document diagnostics

Git Integration

  • <C-h> - File commit history

๐ŸŽจ Themes and UI

Color Scheme

  • Primary: Nightfox theme with custom modifications
  • Truecolor: Full 24-bit color support
  • Consistent: Unified color palette across all UI elements

UI Components

  • Status Line: Custom lualine configuration with Git integration
  • Tab Line: Custom tabby setup with buffer information
  • File Explorer: Neo-tree with Git status indicators
  • Notifications: Snacks.nvim for elegant notifications

๐Ÿ”ง Customization

Adding New Plugins

Create a new file in lua/plugins/ and it will be automatically loaded:

-- lua/plugins/my-plugin.lua
return {
    "author/plugin-name",
    config = function()
        -- Plugin configuration
    end
}

Custom Keybindings

Add keybindings using the rikka helper:

local rikka = require("rikka")
rikka.setKeymap("n", "<leader>x", ":command<CR>", { desc = "Description" })

Language Server Setup

Add new language servers in the lsp/ directory following the existing patterns.

๐Ÿ› Troubleshooting

Plugin Issues

:Lazy health      " Check plugin health
:Lazy sync        " Update plugins
:Lazy clean       " Remove unused plugins

General Health Check

:checkhealth      " Comprehensive health check

๐Ÿ“š Resources

Related Articles

Documentation

๐Ÿ“„ License

This configuration is open source and available under the MIT License.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published