Our great sponsors
-
The airblade/vim-rooter plugin is an essential part of my Neovim workflow. It automatically changes current directory (:h current-directory) for every buffer to a more natural one (like to path of its Git repository). For me this has the following benefits:
-
mini.nvim
Library of 20+ independent Lua modules improving overall Neovim (version 0.7 and higher) experience with minimal effort
Initially I planned to make a separate 'mini.root' module, but realized that it would mostly be a reimplementation of vim.fs. So instead I decided to add setup_auto_root() function to mini.misc. If you want a more tested and documented solution, check it out and tell me what you think. Thanks!
-
SonarQube
Static code analysis for 29 languages.. Your projects are multi-language. So is SonarQube analysis. Find Bugs, Vulnerabilities, Security Hotspots, and Code Smells so you can release quality code every time. Get started analyzing your projects today for free.
-
Firstly, I respect your sharing here, but I still discourage people(especially newcomers) from using this kind of plugin/script to auto-changing "current directory". (So yes, I myself discourage people from using my own root plugin NeoRoot.lua anymore, and I've decided to execute my plan to abandon it recently.)
-
There are indeed three levels of Vim's "current directory", I made a summary during my development of the not well-known multi-tab project session automation plugin: https://github.com/nyngwang/suave.lua/issues/1. In short: it is not that simple.
Related posts
- A Minimal Neovim Configuration for TypeScript Development featuring Lazy.nvim, LSP, Tree-Sitter, Prettier, Guess-Indent
- is there is a session manager plugin ?
- flatten.nvim - open files from a neovim terminal in your current neovim instance - no more nested neovim sessions!
- Tools for productivity
- mini.move - Move any selection in any direction