fix: config.setup deprecation checks
parent
aa3fdbc8a5
commit
029ba65f39
|
|
@ -37,6 +37,7 @@ function M.setup(opts)
|
||||||
M.options = vim.tbl_deep_extend("force", {}, defaults, opts or {})
|
M.options = vim.tbl_deep_extend("force", {}, defaults, opts or {})
|
||||||
vim.fn.mkdir(M.options.save_dir, "p")
|
vim.fn.mkdir(M.options.save_dir, "p")
|
||||||
|
|
||||||
|
if opts then
|
||||||
if opts.before_source then
|
if opts.before_source then
|
||||||
require("persisted.deprecate").write(
|
require("persisted.deprecate").write(
|
||||||
"----------\n",
|
"----------\n",
|
||||||
|
|
@ -90,7 +91,7 @@ function M.setup(opts)
|
||||||
{ "telescope.before_source", "ErrorMsg" },
|
{ "telescope.before_source", "ErrorMsg" },
|
||||||
" callback.\nPlease replace with the ",
|
" callback.\nPlease replace with the ",
|
||||||
{ "PersistedTelescopeLoadPre", "WarningMsg" },
|
{ "PersistedTelescopeLoadPre", "WarningMsg" },
|
||||||
{ " user event. This will be removed from the plugin on "},
|
{ " user event. This will be removed from the plugin on " },
|
||||||
{ "2023-03-05", "WarningMsg" }
|
{ "2023-03-05", "WarningMsg" }
|
||||||
)
|
)
|
||||||
end
|
end
|
||||||
|
|
@ -101,10 +102,11 @@ function M.setup(opts)
|
||||||
{ "telescope.after_source", "ErrorMsg" },
|
{ "telescope.after_source", "ErrorMsg" },
|
||||||
" callback.\nPlease replace with the ",
|
" callback.\nPlease replace with the ",
|
||||||
{ "PersistedTelescopeLoadPost", "WarningMsg" },
|
{ "PersistedTelescopeLoadPost", "WarningMsg" },
|
||||||
{ " user event. This will be removed from the plugin on "},
|
{ " user event. This will be removed from the plugin on " },
|
||||||
{ "2023-03-05", "WarningMsg" }
|
{ "2023-03-05", "WarningMsg" }
|
||||||
)
|
)
|
||||||
end
|
end
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
return M
|
return M
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue