1- *lsp-timeout.txt* Last change: 2023 September 29
1+ *lsp-timeout.txt* Last change: 2023 October 16
22
33==============================================================================
44Table of Contents *lsp-timeout-table-of-contents*
55
66OVERVIEW .............................................. | lsp-timeout-overview |
77INSTALL ................................................ | lsp-timeout-install |
8+ UPDATE .................................................. | lsp-timeout-update |
89CONFIGURATION .................................... | lsp-timeout-configuration |
10+ TROUBLESHOOTING ................................ | lsp-timeout-troubleshooting |
11+ null-ls ................................................ | lsp-timeout-null-ls |
912
1013------------------------------------------------------------------------------
1114OVERVIEW *lsp-timeout-overview*
1215
1316
14- Nvim plugin for nvim-lspconfig: stop idle servers & restart upon focus; keep
15- your RAM usage low
17+ Nvim plugin for nvim-lspconfig: stop idle servers & restart upon gaining or
18+ loosing focus; keep your RAM usage low;
1619
1720
1821------------------------------------------------------------------------------
@@ -22,43 +25,82 @@ INSTALL *lsp-timeout-install*
2225Use your favorite package manager (Packer, Plug, Lazy.nvim etc.)
2326
2427>
25- "hinell/lsp-timeout.nvim",
28+ "hinell/lsp-timeout.nvim"
2629<
2730Prerequisites:
2831
29- >
30- "neovim/nvim-lspconfig"
31- <
32+ * Neovim v0.7.2+
33+ * `" neovim/nvim-lspconfig" `
3234E.g. for packer:
3335
3436>lua
3537 -- $HOME/.config/nvim/lua/user/init.lua
38+ -- Don't forget to run :PackerCompile
3639 packer.setup(function(use)
3740 use({
38- "hinell/lsp-timeout.nvim",
39- requires={ "neovim/nvim-lspconfig" },
41+ "hinell/lsp-timeout.nvim",
42+ requires={ "neovim/nvim-lspconfig" },
4043 setup = function()
4144 vim.g["lsp-timeout-config"] = {
42- ...
45+ --
4346 }
4447 end
4548 })
4649 end)
4750<
51+ Lazy.nvim:
52+
53+ >lua
54+ {
55+ "hinell/lsp-timeout.nvim",
56+ dependencies={ "neovim/nvim-lspconfig" },
57+ init = function()
58+ vim.g["lsp-timeout-config"] = {
59+ --
60+ }
61+ end
62+ }
63+ <
64+
65+ ------------------------------------------------------------------------------
66+ UPDATE *lsp-timeout-update*
67+
68+
69+ You may want to reinstall this plugin manually because of specific
70+ dev-approach: repo of this plugin may be force-pushed & force-rebased,
71+ rendering all previous commits obsolete; read DEVELOPMENT.md for more info
72+
4873
4974------------------------------------------------------------------------------
5075CONFIGURATION *lsp-timeout-configuration*
5176
5277
5378>lua
5479 vim.g["lsp-timeout-config"] = {
55- -- When focus is lost
56- -- wait 5 minutes before stopping all LSP servers
57- stopTimeout=1000 * 60 * 5,
58- startTimeout=1000 * 10
80+ stopTimeout = 1000 * 60 * 5, -- ms, timeout before stopping all LSP servers
81+ startTimeout = 1000 * 10, -- ms, timeout before restart
82+ silent = false -- true to suppress notifications
5983 }
6084<
61- September 16, 2023
85+
86+
87+ TROUBLESHOOTING *lsp-timeout-troubleshooting*
88+
89+ **Note** IF SOME PLUGIN FAILED BECAUSE OF STOPPED LSP, PLEASE, FILL AN ISSUE
90+ IN THE RESPECTIVE PLUGIN REPO
91+
92+ * Some LSP servers which don't keep cache on hdd may fail.
93+ * Some plugins that require active LSP servers like those used for signs may
94+ also fail: if they don't hook into | LspAttach | or | LspDetach | events or if
95+ they don't use `vim .lsp .get_clients (... )` .
96+
97+
98+ NULL-LS *lsp-timeout-null-ls*
99+
100+ Please, see
101+ https://github.com/hinell/lsp-timeout.nvim/issues/7#issuecomment-1764402683
102+
103+ September 26, 2023
62104Copyright - Alexander Davronov, et.al.<br>
63105
64106
0 commit comments