feat: A working state during the transfer between the old neovim

configurations and using newer built-in functionality in the 0.12.x
versions of Neovim.

Further work is needed for treesitter updates, cleanup of the conversion
work and testing to verify old functionality isn't lessened to get the
benefits of a cleaner config and vastly faster load times.
This commit is contained in:
2026-05-23 20:28:34 -05:00
parent deea09dac5
commit abe81c01b3
28 changed files with 490 additions and 609 deletions

View File

@@ -1,12 +1,20 @@
return {
'L3MON4D3/LuaSnip',
config = function()
require('luasnip.loaders.from_vscode').lazy_load()
require('luasnip.loaders.from_lua').lazy_load({ paths = "./snippets" })
end,
dependencies = {
'saadparwaiz1/cmp_luasnip', -- Wrapper to load snippets in nvim-cmp
'rafamadriz/friendly-snippets',
},
build = "make install_jsregexp"
}
vim.pack.add({
'https://github.com/saadparwaiz1/cmp_luasnip',
'https://github.com/rafamadriz/friendly-snippets',
'https://github.com/L3MON4D3/LuaSnip'
})
local luasnip_lua_path = vim.api.nvim_get_runtime_file('lua/luasnip/init.lua', false)[1]
if not luasnip_lua_path then return end
local luasnip_root = vim.fn.fnamemodify(luasnip_lua_path, ':h:h:h')
vim.api.nvim_create_autocmd('PackChanged', { callback = function(args)
local name, kind = args.data.spec.name, args.data.kind
if name == 'luasnip' and kind == 'update' then
if not args.data.active then vim.cmd.packadd('luasnip') end
vim.system({'make', 'install_jsregexp'}, { cwd = luasnip_root })
end
end})
require('luasnip.loaders.from_vscode').lazy_load()
require('luasnip.loaders.from_lua').lazy_load({ paths = "./snippets" })