- Purpose: Code review workflow — file navigation, LSP go-to-definition, syntax highlighting
- Plugin manager: lazy.nvim with lazy-loading (event/cmd/keys triggers)
- Settings: Single source of truth in
lua/settings.lua— do NOT duplicate vim options elsewhere - Diagnostics: Consolidated in
lua/plugins/nvim-lspconfig.lua— do NOT configure diagnostics in lspsaga or other plugins - Performance: Runtime-only logic in
lua/performance.lua, runs BEFORE lazy.nvim loads - Leader key:
\(backslash) - No completion engine: LSP capabilities via
vim.lsp.protocol.make_client_capabilities()
This config uses nvim-treesitter v1.0+ which has major breaking changes from pre-v1.0:
require("nvim-treesitter.configs")was REMOVED — do NOT use itrequire("nvim-treesitter").setup({})only acceptsinstall_dir, noensure_installed:TSInstalland:TSUpdatecommands were REMOVED — we re-add them innvim-treesitter.lua- Highlighting is enabled via
vim.treesitter.start(buf), not plugin config - Indentation uses
vim.bo.indentexpr = "v:lua.require'nvim-treesitter'.indentexpr()"
- Requires
tree-sitter-cli(brew install tree-sitter-cli) — NOT thetree-sitterlibrary require("nvim-treesitter").install()async can hang inside nvim — compile manually if needed- Parsers install to
~/.local/share/nvim/site/parser/<lang>.so - Revision tracking in
~/.local/share/nvim/site/parser-info/<lang>.revision - Some grammars (e.g., swift) need
tree-sitter generatebeforetree-sitter build - Get parser info:
:lua print(vim.inspect(require("nvim-treesitter.parsers").<lang>))
cd /tmp && curl -sL "https://github.com/<repo>/archive/<rev>.tar.gz" | tar xz
cd <extracted>/<location> && tree-sitter build -o parser.so
cp parser.so ~/.local/share/nvim/site/parser/<lang>.so
echo "<rev>" > ~/.local/share/nvim/site/parser-info/<lang>.revision- ESLint server uses
root_dirdetection — only starts in projects with ESLint config files - Detects:
.eslintrc.*,eslint.config.*(js/mjs/cjs) - Will NOT start in projects without ESLint config (no "Unable to find ESLint library" warnings)
- Each plugin has its own file in
lua/plugins/ - lazy.nvim
cmd = {}creates stub commands that trigger plugin load — use this for commands defined insideconfig - Use
config = function() ... endinstead ofopts = {}when the plugin module might not be installed yet (e.g., snacks.nvim) - All autocmds inside plugin configs MUST use an augroup with
clear = trueto prevent accumulation on:ReloadConfig
| Removed | Reason |
|---|---|
| blink.cmp, friendly-snippets | No completion needed for code review |
| conform.nvim | No formatting needed |
| nvim-autopairs | No coding |
| nvim-surround | No coding |
| grug-far.nvim | No search/replace needed |
| bufferline.nvim | fzf-lua buffers + C-n/C-p suffice |
| schemastore.nvim | No JSON schema editing |
| telescope, nvim-cmp, alpha-nvim, fidget, leap, copilot, vim-commentary, wilder, lspkind, nvim-spectre, nvim-treesitter-textobjects | Previously disabled, now deleted |
lazy-lock.json: If empty (0 bytes), delete it — causes "commit is nil" errors. lazy.nvim regenerates it on next startup*.cloningfiles in~/.local/share/nvim/lazy/: Lock files from interrupted installs — delete them before retrying- Neovim 0.11 renamed
vim.treesitter.language.ft_to_langtoget_lang vim.o.ttyfastis NOT a valid Neovim option — don't set it- For buffer size checks, use
vim.api.nvim_buf_get_offset()for O(1) instead of iterating lines regexpengine = 0(auto) is better than1(forced old engine)
- Config source:
~/Library/Mobile Documents/com~apple~CloudDocs/Documents/Expedia Group/settings/config/nvim/ - Symlinked to:
~/.config/nvim/ - Plugin data:
~/.local/share/nvim/lazy/ - Parser binaries:
~/.local/share/nvim/site/parser/ - State/logs:
~/.local/state/nvim/ - Git repo:
https://github.com/elsonwu/vim.git(branch:lsp)
TypeScript, JavaScript, TSX, JSON, YAML, Lua, Vim, Vimdoc, Markdown, Swift, Kotlin (treesitter parsers installed)
LSP servers (via Mason): vtsls (TS/JS), jdtls (Java), yamlls (YAML), lua_ls (Lua), eslint (auto-detect)