-
Notifications
You must be signed in to change notification settings - Fork 27.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Default setting + frequent :w
= use up all the ram and system freeze
#89
Comments
same issue 👍 |
Yes, after that stage, the automatic recompile is indeed a very good feature. I though it is the issue of |
Hmm, that's a good point... I wonder if there is a way for us to prevent multiple language servers from being spawned. Perhaps adding |
Personally I just commented the code responsible for automatic source & re-compile. local packer_group = vim.api.nvim_create_augroup('Packer', { clear = true })
vim.api.nvim_create_autocmd('BufWritePost', {
command = 'source <afile> | PackerCompile',
group = packer_group,
pattern = vim.fn.expand '$MYVIMRC',
}) The lua language server (semnko_lua?) starts every time I do |
I can confirm the bad behaviour and also @senicko observation. Also I checked up |
It eats RAM. See nvim-lua/kickstart.nvim#89
The purpose of the code is because Packer has some confusing behavior to people on first attempt of using it. So this attempts to fix that, at least for starting up. Yes you can just remove the code if you're already aware of how to use Packer. I will explore some options of how to solve the problem after Christmas. |
Thanks for your advice!!! Line 90 in 39a941c
with this: command = 'source <afile> | silent! LspStop | silent! LspStart | PackerCompile', Now I can press Thank for your work in kickstart.nvim! |
Thanks :) I think I may actually try and switch kickstart to the new |
From the youtube video https://y.com.sb/watch?v=stqUbv-5u2s, I notice this project exist.
So I want to test it out and replace my old init.vim and explore more about lua.
However, while playing around with the init.lua, my system freeze.
Below is how to reproduce it:
Running
nvim ~/.config/nvim/init.lua
with default setting.in
htop
it will display it spawn a processlua-language-server
when I press
:w
Enter
, one morelua-language-server
spawn, and use up maybe more 2% of ram.when I do the
:w
Enter
again, and use more 2% of ram. and so onHowever I just have a bad habit to frequently save the files.
When I do
:w
too frequently, say 1 sec once for 15 secThe ram usage surge rapidly, which is much more than 2% per
:w
mentioned aboveand my system freeze.
And I later find out that it is caused by
"Automatically source and re-compile packer whenever you save this init.lua"
setting.Just simply do a
:wq
also help release the ram.Since this script may target new user of neovim as stated in the video
I think it worth mentioning in the readme file.
The text was updated successfully, but these errors were encountered: