[mini.deps] hook not executing #1563
-
Contributing guidelines
Module(s)mini.deps QuestionHello! I can't get the 'hooks' part of mini.deps working. The LuaSnip plugin is installed with the correct version, but the hook seemingly never executes. There's nothing in If I navigate to the plugin directory and run the What am I doing wrong? now(function()
add {
source = 'L3MON4D3/LuaSnip',
checkout = 'v2.3.0',
hooks = {
post_checkout = function(spec)
print('spec.path: ' .. spec.path)
vim.fn.system({'make', 'install_jsregexp'}, {cwd = spec.path})
end }
}
end) |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
The What you probably experience is that it doesn't trigger on the initial install. There is |
Beta Was this translation helpful? Give feedback.
The
post_checkout
hook is executed after making change to an existing plugin, i.e. after downloading update or switching to different commit/branch/tag locally.What you probably experience is that it doesn't trigger on the initial install. There is
post_install
hook for that. Try adding the same function in thepost_install
hook. If the hook itself executes but throws an error (although I don't think it should in this particular case), try executing the same function insidelater()
.