aboutsummaryrefslogtreecommitdiff
path: root/runtime/lua/vim/loader.lua
diff options
context:
space:
mode:
authorLewis Russell <lewis6991@gmail.com>2023-03-26 12:47:06 +0100
committerLewis Russell <lewis6991@gmail.com>2023-03-26 12:47:06 +0100
commitfab8dab6b6273767e2b31e4282cee5a11349ac8f (patch)
treeeb2d73ca925e101aa9609503ec9f4469c4ad6a1e /runtime/lua/vim/loader.lua
parent3c82ce0d625184a90e6b2dda96e38fcb44f901d2 (diff)
downloadrneovim-fab8dab6b6273767e2b31e4282cee5a11349ac8f.tar.gz
rneovim-fab8dab6b6273767e2b31e4282cee5a11349ac8f.tar.bz2
rneovim-fab8dab6b6273767e2b31e4282cee5a11349ac8f.zip
refactor(loader): remove BufWritePost autocmd
Diffstat (limited to 'runtime/lua/vim/loader.lua')
-rw-r--r--runtime/lua/vim/loader.lua14
1 files changed, 0 insertions, 14 deletions
diff --git a/runtime/lua/vim/loader.lua b/runtime/lua/vim/loader.lua
index bafe766a5d..3dc1bd9574 100644
--- a/runtime/lua/vim/loader.lua
+++ b/runtime/lua/vim/loader.lua
@@ -409,19 +409,6 @@ function M.enable()
break
end
end
-
- -- this will reset the top-mods in case someone adds a new
- -- top-level lua module to a path already on the rtp
- vim.api.nvim_create_autocmd('BufWritePost', {
- group = vim.api.nvim_create_augroup('cache_topmods_reset', { clear = true }),
- callback = function(event)
- local bufname = event.match ---@type string
- local idx = bufname:find('/lua/', 1, true)
- if idx then
- M.reset(bufname:sub(1, idx - 1))
- end
- end,
- })
end
--- Disables the experimental Lua module loader:
@@ -440,7 +427,6 @@ function M.disable()
end
end
table.insert(package.loaders, 2, vim._load_package)
- vim.api.nvim_del_augroup_by_name('cache_topmods_reset')
end
--- Return the top-level `/lua/*` modules for this path