feat: modernize Neovim setup, pin treesitter, add check script, and improve install process#3
Open
aggiebill wants to merge 6 commits into
Open
Conversation
Only show the 'edit your gitconfig' message for fresh installs where the name field is still empty/placeholder. Users who keep personalized values directly in their local dotfiles repo copy (no longer get the noisy reminder on every run or after updates).
The closing 'EOF' (and opening 'lua << EOF') were indented.
In Vim heredocs, the terminator must start at column 0 with no
leading whitespace, otherwise the block never ends and subsequent
Vimscript (the final 'endif') leaks into the Lua chunk.
This caused:
E5107: Error loading lua ... '=' expected near 'endif'
E171: Missing :endif
on Neovim startup.
Also verified: the block is defensive (pcall + has('nvim-0.9')),
so it is a no-op unless the user manually installs nvim-treesitter.
- Extract the treesitter setup to nvim/lua/treesitter.lua - Load it with a protected 'lua pcall(require, "treesitter")' - This completely removes the inline 'lua << EOF ... EOF' heredoc (and the confusing EOF marker line) from init.vim. - Update install.sh to symlink the lua/ directory so requires work. - Much cleaner, follows the 'put Lua files under lua/' guidance already present in the comments, and avoids Vim heredoc gotchas. The optional treesitter block now works without any EOF line at all.
…perience Added common supporting languages (json, yaml, toml, dockerfile, make, regex, comment) in addition to python + bash. This gives better highlighting/indent/incremental selection across more file types the user is likely to edit daily, while keeping the focus on Python and shell.
…larify :TSInstall usage - The cloned nvim-treesitter (main branch) uses a slimmer API: - No more 'nvim-treesitter.configs' (it's now 'nvim-treesitter.config') - No old-style modules for highlight/indent/incremental_selection - :TSInstall requires arguments (nargs='+') — bare command errors with E471 - Updated our treesitter.lua: - Auto-triggers missing parsers via the install module (replaces ensure_installed) - Uses vim.treesitter.start() for highlighting on python/bash/etc. filetypes - Wires up nvim_treesitter#indent() for superior indentation - Uses Neovim's builtin treesitter foldexpr - Documents the lack of built-in incremental_selection in this version - Clarified docs in init.vim so users don't hit the 'argument expected' surprise. This should now deliver the great Python + shell treesitter experience (highlighting + indent) with the parser manager we have installed.
…mprove install process - Upgrade Neovim installation to use latest official tarball (v0.12+) instead of outdated apt package in Ubuntu 26.04 - Pin nvim-treesitter to v0.9.3 for compatibility with Neovim 0.11/0.12 and update treesitter.lua to use classic nvim-treesitter.configs.setup with ensure_installed for python, bash + supporting languages - Add comprehensive check.sh script for feature-by-feature status verification of the entire dotfiles setup - Update install.sh to fully automate: latest Neovim tarball, pinned treesitter plugin checkout, tree-sitter CLI binary, PATH setup, and parser auto-install on first nvim run - Prepend ~/.local/bin to PATH in bash_aliases (instead of append) so local Neovim, uv, ruff, tree-sitter CLI take precedence - Improve and expand documentation in README.md and nvim/init.vim with precise install/pin/CLI steps and troubleshooting notes - Add runtimepath append in treesitter.lua to fix 'install directory not in runtimepath' health warning - Clean up legacy neofetch references, update MOTD, ensure submodules and symlinks are handled - Add tree-sitter CLI installation step for full :TSInstall / health support These changes deliver a reproducible, modern Neovim + Tree-sitter experience (highlighting, indent, incremental selection for Python/shell) with automated verification via ./check.sh. All features now match the state achieved during the session.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR brings the dotfiles repo up to the fully modernized state achieved in our session:
After
./install.sh(or manual equivalent), start Neovim once to let ensure_installed fetch parsers, then use./check.shto verify the state. This delivers a clean, up-to-date Neovim + Tree-sitter Python/shell experience withgnn/grnselection, superior highlighting/indent, etc.Ready for review and merge. All changes tested on the target machine.