mirror of
https://github.com/dcarrillo/dotfiles.git
synced 2024-12-22 19:48:01 +00:00
[neovim] Disable illuminate on very large files
This commit is contained in:
parent
6066f801c6
commit
5a13d12e33
@ -32,3 +32,13 @@ vim.api.nvim_create_autocmd({ "FileType" }, {
|
||||
]])
|
||||
end,
|
||||
})
|
||||
|
||||
-- Disable illuminate on very large files
|
||||
vim.api.nvim_create_autocmd({ "BufWinEnter" }, {
|
||||
callback = function()
|
||||
local line_count = vim.api.nvim_buf_line_count(0)
|
||||
if line_count >= 5000 then
|
||||
vim.cmd("IlluminatePauseBuf")
|
||||
end
|
||||
end,
|
||||
})
|
||||
|
Loading…
Reference in New Issue
Block a user