aboutsummaryrefslogtreecommitdiffstats
path: root/lua/lspconfig/configs/lua_ls.lua
Commit message (Collapse)AuthorAgeFilesLines
* refactor: deprecate util.find_git_ancestordundargoc2024-12-141-1/+1
| | | | Work on https://github.com/neovim/nvim-lspconfig/issues/2079.
* refactor: replace all instances of vim.uv with vim.loopdundargoc2024-12-021-1/+1
| | | | | We still support neovim 0.9 currently, so we can't use vim.uv. Also add a check so we don't accidentally reintroduce it.
* fix(lua_ls): when neither lua or git root found, return nil. See #3322 (#3391)Folke Lemaitre2024-10-221-0/+3
|
* docs(lua_ls): hint about personal config #3381Jean-Charles Quillet2024-10-181-1/+1
|
* refactor: replace deprecated vim.loop with vim.uvdundargoc2024-10-021-1/+1
|
* fix(lua-language-server): root directory pattern #3322Peter Kling2024-10-011-8/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Problem: Looking at the code for root dir detection for `lua_ls`: https://github.com/neovim/nvim-lspconfig/blob/9bda20fb967075355f253911bc066a8b5a03c77e/lua/lspconfig/server_configurations/lua_ls.lua#L17-L27 I was surprised that finding the git ancestor has lower priority than the `lua/` subdirectories (which, btw, is not mentioned in docs). Consider the following directory structure: HOME/ ├─ workspaces/ │ ├─ lua/ │ ├─ python/ │ ├─ work/ │ │ ├─ SomeProjectWithLuaFiles/ │ │ │ ├─ .git/ The `lua/` and `python/` directories contain some miscellaneous language-specific projects I sometimes work on. The project directory under work/ also contains some lua files. I expected the `.git` directory in the project to ensure that the project root dir is correctly detected to be `…/SomeProjectWithLuaFiles`. But since the [search for the `lua/` subdirectory](https://github.com/neovim/nvim-lspconfig/blob/9bda20fb967075355f253911bc066a8b5a03c77e/lua/lspconfig/server_configurations/lua_ls.lua#L22) is done first, my LSP detects `HOME/workspaces/` as the root directory. Solution: Search for the git ancestor before looking for the `lua/` subdirectory. Return the longer root path if both a `.git/` and a `lua/` ancestor are found. Fixes #3165
* refactor: rename "server_configurations" => "configs" #3330Justin M. Keyes2024-10-011-0/+90
Problem: The name `server_configurations` is extremely verbose and irritatingly formal and dogmatic. This overlong name is a constant nuisance when reading, writing, and coding. It's also not even correct: these configurations are just as much "client" configurations as they are "server" configurations. Solution: - Rename to a shorter name. - Leave placeholder files for any old URLs that link to the old location.