Skip to content
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

Error than entering nvim #60

Open
Bogdan-Torkhov opened this issue Sep 28, 2022 · 0 comments
Open

Error than entering nvim #60

Bogdan-Torkhov opened this issue Sep 28, 2022 · 0 comments

Comments

@Bogdan-Torkhov
Copy link

Error detected while processing /home/deusbog/.local/share/nvim/plugged/auto-save.nvim/plugin/auto-save.lua: E5113: Error while calling lua chunk: ...share/nvim/plugged/auto-save.nvim/lua/auto-save/init.lua:100: unexpected event stack traceback: [C]: in function 'nvim_create_autocmd' ...share/nvim/plugged/auto-save.nvim/lua/auto-save/init.lua:100: in function 'on' ...l/share/nvim/plugged/auto-save.nvim/plugin/auto-save.lua:14: in main chunk
Have these error than entering nvim. System:ubuntu 22.04,nvim 7.2
My config for plugin : require("auto-save").setup { enabled = true, -- start auto-save when the plugin is loaded (i.e. when your package manager loads it) execution_message = { message = function() -- message to print on save return ("AutoSave: saved at " .. vim.fn.strftime("%H:%M:%S")) end, dim = 0.18, -- dim the color of messagecleaning_interval = 1000, -- (milliseconds) automatically clean MsgArea after displayingmessage`. See :h MsgArea
},
trigger_events = {"InsertLeave", "TextChanged", "BufNew", "BudLeave", "BufAdd", "BufDelete", "BufEnter", "UIEnter", "UILeave", "InsertChange", "InserEnter", "TabEnter", "TabLeave", "TabNew", "TabNewEntered", "TabClosed", "TermOpen", "TermEnter", "TermLeave", "TermClose", "TermResponse", "TextChanged", "TextChangedI", "TextChangedP", "VimEnter", "VimLeave", "VimResized", "VimResume", "VimSuspend", "WinClosed", "WinEnter", "WinLeave", "WinNew"},
condition = function(buf)
local fn = vim.fn
local utils = require("auto-save.utils.data")

	if
		fn.getbufvar(buf, "&modifiable") == 1 and
		utils.not_in(fn.getbufvar(buf, "&filetype"), {}) then
		return true -- met condition(s), can save
	end
	return false -- can't save
end,
write_all_buffers = false, -- write all buffers when the current one meets `condition`
debounce_delay = 100, -- saves the file at most every `debounce_delay` milliseconds
callbacks = { -- functions to be executed at different intervals
	enabling = nil, -- ran when enabling auto-save
	disabling = nil, -- ran when disabling auto-save
	before_asserting_save = nil, -- ran before checking `condition`
	before_saving = nil, -- ran before doing the actual save
	after_saving = nil -- ran after doing the actual save

}

}`

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant