feat: rename experimental_watch_for_changes -> watch_for_changes

I've been using this for a while now and haven't seen any issues. We can
take "experimental" out of the name.
This commit is contained in:
Steven Arcangeli 2024-07-01 11:34:02 -07:00
parent 65c53dbe4f
commit c7c7ce5bd4
5 changed files with 10 additions and 5 deletions

View file

@ -50,7 +50,7 @@ local default_config = {
-- Set to `false` to disable, or "name" to keep it on the file names
constrain_cursor = "editable",
-- Set to true to watch the filesystem for changes and reload oil
experimental_watch_for_changes = false,
watch_for_changes = false,
-- Keymaps in oil buffer. Can be any value that `vim.keymap.set` accepts OR a table of keymap
-- options with a `callback` (e.g. { callback = function() ... end, desc = "", mode = "n" })
-- Additionally, if it is a string that matches "actions.<name>",
@ -207,6 +207,11 @@ M.setup = function(opts)
)
end
-- This option was renamed because it is no longer experimental
if new_conf.experimental_watch_for_changes then
new_conf.watch_for_changes = true
end
for k, v in pairs(new_conf) do
M[k] = v
end