diff options
| author | Paul Gideon Dann <pdgiddie@gmail.com> | 2023-11-22 05:40:41 +0000 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-11-22 13:40:41 +0800 |
| commit | 3ede70ccb292b20020f194b42d9508946fc5da51 (patch) | |
| tree | eb44057307a2039556bcbb4d54c3349f1199f173 | |
| parent | docs: update server_configurations.md (diff) | |
| download | nvim-lspconfig-3ede70ccb292b20020f194b42d9508946fc5da51.tar nvim-lspconfig-3ede70ccb292b20020f194b42d9508946fc5da51.tar.gz nvim-lspconfig-3ede70ccb292b20020f194b42d9508946fc5da51.tar.bz2 nvim-lspconfig-3ede70ccb292b20020f194b42d9508946fc5da51.tar.lz nvim-lspconfig-3ede70ccb292b20020f194b42d9508946fc5da51.tar.xz nvim-lspconfig-3ede70ccb292b20020f194b42d9508946fc5da51.tar.zst nvim-lspconfig-3ede70ccb292b20020f194b42d9508946fc5da51.zip | |
fix(elixirls): root_dir priority: mix.exs > .git (#2910)
If we're in a subdirectory of a git repo, and that subdirectory contains
a mix.exs file, it makes sense to assume the subdirectory is the project
root, rather than the git repo root.
| -rw-r--r-- | lua/lspconfig/server_configurations/elixirls.lua | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lua/lspconfig/server_configurations/elixirls.lua b/lua/lspconfig/server_configurations/elixirls.lua index 1ae3d8c8..62b8e168 100644 --- a/lua/lspconfig/server_configurations/elixirls.lua +++ b/lua/lspconfig/server_configurations/elixirls.lua @@ -4,7 +4,7 @@ return { default_config = { filetypes = { 'elixir', 'eelixir', 'heex', 'surface' }, root_dir = function(fname) - return util.find_git_ancestor(fname) or util.root_pattern 'mix.exs'(fname) or vim.loop.os_homedir() + return util.root_pattern 'mix.exs'(fname) or util.find_git_ancestor(fname) or vim.loop.os_homedir() end, }, docs = { |
