Skip to content

Upgrade to Neovim 0.12 and nvim-treesitter main - #15

Merged
SimonKimDev merged 1 commit into
mainfrom
simonk/dev/nvim-0.12
Oct 17, 2026
Merged

SimonKimDev merged 1 commit into
mainfrom
simonk/dev/nvim-0.12

Conversation

@SimonKimDev

Copy link
Copy Markdown
Owner

Moves the config to Neovim 0.12 (CI: 0.12.6), which also unblocks rustaceanvim v9 for Rust support in a follow-up PR.

nvim-treesitter's master branch doesn't support 0.12, so this migrates to its main rewrite:

  • lazy/treesitter.lua: only installs parsers. A FileType autocmd starts Neovim's built-in highlighting (and nvim-treesitter's experimental indentexpr, as before) wherever a parser exists.
  • Incremental selection: <C-space> / <bs> now drive 0.12's built-in an / in. Checked headlessly: bar → (bar, baz) → foo(bar, baz) → back.
  • nvim-ts-autotag: own setup(), since nvim-treesitter.configs is gone.
  • tree-sitter CLI: required to compile parsers; Mason installs it (tree-sitter-cli), and parsers install once Mason finishes on a fresh machine.
  • lazy_init.lua creates stdpath("data")/site before lazy.nvim sets the runtimepath. Neovim drops that entry if the directory doesn't exist, so on a fresh machine parsers installed there didn't load until a restart. Found by the smoke test.
  • neotest-golang v2 (needs treesitter main) and all plugins updated to their latest commits.

CI: setup-nvim installs Neovim 0.12.6 and tree-sitter CLI 0.27.1. The smoke test now waits for every parser to install and checks Go/TSX/Lua buffers get treesitter highlighting.

Tested locally on 0.12.6: fresh smoke run passes in ~60s, including compiling all 25 parsers with gcc; :checkhealth vim.deprecated reports nothing; all parsers show in :checkhealth nvim-treesitter.

To use it locally after merging:

  1. choco uninstall neovim (admin) so nvim resolves to the winget 0.12.6 install.
  2. Delete %LOCALAPPDATA%\nvim-data\lazy\nvim-treesitter (it has old master parsers in it), then pull and start Neovim. I can do this step.

nvim-treesitter's master branch doesn't support Neovim 0.12, so move to
the main rewrite:

- treesitter.lua only installs parsers; a FileType autocmd starts
  Neovim's built-in highlighting and nvim-treesitter's indentexpr.
- Incremental selection maps (<C-space>, <bs>) now use 0.12's built-in
  `an`/`in`. nvim-ts-autotag gets its own setup() instead of the removed
  configs module.
- Parsers are compiled with the tree-sitter CLI, which Mason installs;
  parsers install again once Mason finishes on a fresh machine.
- lazy_init.lua creates stdpath("data")/site before lazy.nvim sets the
  runtimepath. Neovim drops it from the runtimepath if it's missing, so
  parsers installed there on a fresh machine didn't load until a restart.
- neotest-golang v2, which needs treesitter main.
- All plugins updated to their latest commits under 0.12.

CI installs Neovim 0.12.6 and a pinned tree-sitter CLI. The smoke test
waits for every parser to install and checks that go, tsx and lua
buffers get treesitter highlighting.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Copilot-Session: 90315f97-7c82-4bc1-9bf1-2f8460782554
@SimonKimDev
SimonKimDev marked this pull request as ready for review October 17, 2026 10:53
@SimonKimDev
SimonKimDev merged commit 9397937 into main Oct 17, 2026
3 checks passed
@SimonKimDev
SimonKimDev deleted the simonk/dev/nvim-0.12 branch October 17, 2026 10:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant