Closed ls-devs closed 11 months ago
@ls-devs Are you requesting an option to prevent lsp-timeout
from starting up servers if currently focused nvim window is in ignored
list?
@hinell Yes. But in certains conditions :
lsp-timeout
did not shutdown the servers.ignored
list.Because actually, lsp-timeout
try to restart servers if the focused window is type of neo-tree
Telescope
etc.. even if the LSP servers did not shutdown, because lsp-timeout
do not find any active LSP in this window.
For example, if u open NeoTree
and u quick ALT-TAB u can see lsp-timeout
trying to restart servers at each ALT-TAB
I'm thinking about the following config design:
config.paths.include = {} -- autocmd patterns for files on which LSP will be started/stopped
config.paths.exclude = {} -- lua patterns for files which are going to be ignored by `lsp-timeout`
config.filetypes.ignore = {} -- like above, but for file types whole strings
Any thoughts / suggestions / objections?
@hinell I think codfig.filetypes.ignore = {}
should be enough for the user to do what he really wants to.
Not needed to add so complexity for such simple thing.
Problem with non-editable windows is fixed in v1.1.0 release.
I've made a decision to avoid extending config to keep it simple. Now, certain windows are going to be ignored. No ignore lists are used.
Should to addressed in new v1.2.0
release, checkout
Add option to ignore filetypes
It would be great if this plugin could ignore some filetypes like
NeoTree
Telescope
etc.. Actually if u loose focus on a window such likeNeoTree
Telescope
, the plugin try to restart some LSP cause its found 0 servers (even if u just ALT-TAB quickly). But it needs to restart LSPs if they stopped even if focus is regained on an ignored filetype.