How LSP file renaming works with yazi.nvim
mainThe plugin integrates with the Language Server Protocol (LSP) to ensure that when you rename a file within yazi, all references to that file in your project (such as imports) are automatically updated by your LSP server.
Workflow:
- You rename a file inside the
yaziterminal file manager. yazisends a rename event to Neovim via its Data Distribution Service (DDS).- The plugin triggers the LSP
workspace/willRenameFilesrequest. - The LSP server calculates and provides the necessary changes to related files.
- Neovim applies these changes.
- The plugin notifies the LSP server that renaming is finished via
workspace/didRenameFiles.
Requirement: An LSP server must be actively running in your Neovim session for this feature to function.