mirror of
https://github.com/zoriya/auto-save.nvim.git
synced 2026-08-06 22:28:06 +00:00
first commit
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
|
||||
local opts = require("autosave.config").options
|
||||
local cmd = vim.cmd
|
||||
|
||||
local M = {}
|
||||
|
||||
local function setup_commands()
|
||||
if (opts["on_off_commands"] == true) then
|
||||
cmd([[command! ASOn lua require'autosave.main'.main('on')]])
|
||||
cmd([[command! ASOff lua require'autosave.main'.main('off')]])
|
||||
end
|
||||
end
|
||||
|
||||
function M.setup(custom_opts)
|
||||
require("autosave.config").set_options(custom_opts)
|
||||
setup_commands()
|
||||
end
|
||||
|
||||
return M
|
||||
Reference in New Issue
Block a user