diff options
| author | Sola <dev@sola.love> | 2025-05-26 23:30:12 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-05-26 08:30:12 -0700 |
| commit | 2a38a426a240dcc94f2677911598136e839a7b97 (patch) | |
| tree | 1c6dde5ec49eebde4fc08bc925210e36a0a7ea9b /lua | |
| parent | docs: update configs.md (diff) | |
| download | nvim-lspconfig-2a38a426a240dcc94f2677911598136e839a7b97.tar nvim-lspconfig-2a38a426a240dcc94f2677911598136e839a7b97.tar.gz nvim-lspconfig-2a38a426a240dcc94f2677911598136e839a7b97.tar.bz2 nvim-lspconfig-2a38a426a240dcc94f2677911598136e839a7b97.tar.lz nvim-lspconfig-2a38a426a240dcc94f2677911598136e839a7b97.tar.xz nvim-lspconfig-2a38a426a240dcc94f2677911598136e839a7b97.tar.zst nvim-lspconfig-2a38a426a240dcc94f2677911598136e839a7b97.zip | |
fix(fish_lsp): various improvements #3869
Apply suggestions brought up by the `fish_lsp` author:
https://github.com/mason-org/mason-registry/pull/8609#issuecomment-2904347943
Diffstat (limited to 'lua')
| -rw-r--r-- | lua/lspconfig/configs/fish_lsp.lua | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/lua/lspconfig/configs/fish_lsp.lua b/lua/lspconfig/configs/fish_lsp.lua index 8339163e..ad206897 100644 --- a/lua/lspconfig/configs/fish_lsp.lua +++ b/lua/lspconfig/configs/fish_lsp.lua @@ -1,10 +1,12 @@ +local util = require 'lspconfig.util' + return { default_config = { cmd = { 'fish-lsp', 'start' }, - cmd_env = { fish_lsp_show_client_popups = false }, filetypes = { 'fish' }, root_dir = function(fname) - return vim.fs.dirname(vim.fs.find('.git', { path = fname, upward = true })[1]) + return util.root_pattern('config.fish')(fname) + or vim.fs.dirname(vim.fs.find('.git', { path = fname, upward = true })[1]) end, single_file_support = true, }, |
