AgentSkillsCN

nvim

Neovim 配置帮助——插件、键绑定、LSP 设置、故障排除。当用户询问关于 nvim、vim、编辑器配置,或插件相关问题时,可使用此功能。

SKILL.md
--- frontmatter
name: nvim
description: Neovim configuration help - plugins, keybindings, LSP setup, troubleshooting. Use when asked about nvim, vim, editor config, or plugins.

Neovim Configuration

Commands

  • /nvim - Show overview
  • /nvim plugins - List installed plugins
  • /nvim keys - Show key keybindings
  • /nvim add <plugin> - Help add a plugin

Config Location

~/.config/nvim/init.lua (symlinked from ~/.dotfiles/shared/nvim/.config/nvim/)

Stack

  • Base: kickstart.nvim
  • Plugin manager: lazy.nvim

Key Plugins

PluginPurposeKey Binding
nvim-treeFile explorer<leader>e
telescopeFuzzy finder<leader>sf (files), <leader>sg (grep)
treesitterSyntax highlightingautomatic
mason + lspconfigLSP supportautomatic
lazygit.nvimGit TUI<leader>gg
tokyonightColor schemeautomatic

To List Plugins (/nvim plugins)

Read ~/.config/nvim/init.lua and extract plugins from the lazy.setup() call.

To Add a Plugin (/nvim add <plugin>)

  1. Edit ~/.dotfiles/shared/nvim/.config/nvim/init.lua
  2. Add plugin spec to the lazy.setup plugins table:
    lua
    { 'author/plugin-name', opts = {} },
    
  3. Open nvim, run :Lazy install

Troubleshooting

  • Plugins not loading: Open nvim, run :Lazy
  • LSP not working: Run :LspInfo, check :Mason for servers
  • Health check: Run :checkhealth in nvim