feat(nvim): half-baked migration from lazy.nvim to lz.n + vim.pack

This commit is contained in:
Barrett Ruth 2026-02-28 12:43:26 -05:00
parent 60969865b5
commit 50642823bd
Signed by: barrett
GPG key ID: A6C96C9349D2FC81
30 changed files with 865 additions and 1315 deletions

View file

@ -1,6 +1,17 @@
local config = require('config.projects')
vim.api.nvim_create_autocmd('LspAttach', {
callback = function(args)
local client = vim.lsp.get_client_by_id(args.data.client_id)
if client and client.name == 'clangd' then
bmap(
{ 'n', 'gh', vim.cmd.ClangdSwitchSourceHeader },
{ buffer = args.buf }
)
end
end,
group = vim.api.nvim_create_augroup('AClangdKeymap', { clear = true }),
})
local clangd_settings = {
return {
filetypes = { 'c', 'cpp', 'objc', 'objcpp', 'cuda' },
cmd = {
'clangd',
@ -19,21 +30,3 @@ local clangd_settings = {
},
},
}
local project_settings = (config.lsp and config.lsp.clangd)
and config.lsp.clangd
vim.api.nvim_create_autocmd('LspAttach', {
callback = function(args)
local client = vim.lsp.get_client_by_id(args.data.client_id)
if client and client.name == 'clangd' then
bmap(
{ 'n', 'gh', vim.cmd.ClangdSwitchSourceHeader },
{ buffer = args.buf }
)
end
end,
group = vim.api.nvim_create_augroup('AClangdKeymap', { clear = true }),
})
return vim.tbl_extend('force', clangd_settings, project_settings or {})