This commit improves Nixvim's native tree-sitter setup for the modern
nvim-treesitter main branch. The intent was to bring more customizations
that were lost after switching from master branch. In particular:
- `highlight.disable` option now accepts a raw function compatible with
disable parameter from master branch. Additionally it accepts a third
filetype parameter
- add `highlight.enableVimSyntax` option to enable :h syntax for chosen
filetypes. Syntax is sometimes needed for indent files, some vim
scripts, or to improve highlighting for compopund filetypes
- `indent` and `folding` now also have `disable` support
- all features are now enabled only when the parser and queries are
available for current filetype. This avoids setting 'indentexpr' and
'foldexpr' when they cannot work because of missing parser or queries
- adds commands to `b:undo_ftplugin` variable to undo options set. The
content of this variable is automatically executed by Nvim when
switching filetype (by ftplugin). This is needed so that options were
reset if the filetype is changed. Previously stale options were left.
Migrate flake outputs, config files, etc from buildbot-nix to nixbot.
This is not urgent, because nixbot falls back to buildbot-nix.toml when
nixbot.toml is missing.
> ERROR: [ClaudeCode] [config] [WARN] focus_after_send=true does not focus a Claude session running outside Neovim (terminal.provider="external"). Use a `User ClaudeCodeSendComplete` autocmd to focus it yourself.
Include the definition locations of offending vim-plugins in the
`extraPackages` & `extraPackagesAfter` assertion messages.
This makes it easier to track down the plugin declarations,
especially when values originate from multiple modules.
When passing a string to `disabledModules`, it is appended to
`modulesPath`. To avoid this, explicitly pass a `{key}` module.
Adds an assertion module to the platform-wrapper integration tests:
Failed assertions:
- Expected programs.nixvim._module.check to be true. Definitions:
- In `/nix/store/XXXX-source/flake/wrappers.nix': false
Co-authored-by: MrQubo <jakub.jakub.nowak@gmail.com>
Wrapped Nixvim configs previously passed the generated init.lua with -u. Neovim treats that startup path as an explicit user config and skips exrc processing, so project-local .nvim.lua files were not sourced even when users enabled the exrc option.
Load the generated config through a forced VIMINIT instead. This preserves the current wrapped-config precedence while allowing Neovim's normal exrc startup path to run for trusted project config files.
When impureRtp is disabled, clear XDG_CONFIG_DIRS and VIM from an early --cmd before sysinit is checked, then restore them before loading the generated config so runtime code and child processes see the original environment.
Keep the saved startup environment in a short-lived global Lua table shared between the --cmd and VIMINIT chunks, then clear it after restore.
Add a modules-output regression test that checks the wrapper args no longer include -u, verifies VIMINIT is set, confirms trusted .nvim.lua is sourced, blocks sysinit.vim, verifies XDG_CONFIG_DIRS and VIM are restored, and ensures the saved startup state is cleared.
Closes#3506