Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion lua/coldboot/plugins/conform.lua
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ return {
terraform = { 'terraform_fmt' },
hcl = { 'terraform_fmt' },
dockerfile = { 'dockerfmt' },
sql = { 'sqlformat' },
sql = { 'sqlfluff' },
xml = { 'xmlformat' },
},
-- Set up format-on-save
Expand Down
19 changes: 19 additions & 0 deletions lua/coldboot/plugins/lsp.lua
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,17 @@ return {
-- Setup neovim lua configuration
require('neodev').setup()

local function enable_inlay_hints(client, bufnr)
if not client or not client.server_capabilities or not client.server_capabilities.inlayHintProvider then
return
end
if vim.lsp.inlay_hint and type(vim.lsp.inlay_hint) == 'table' and vim.lsp.inlay_hint.enable then
vim.lsp.inlay_hint.enable(true, { bufnr = bufnr })
elseif vim.lsp.buf and vim.lsp.buf.inlay_hint then
vim.lsp.buf.inlay_hint(bufnr, true)
end
end

-- Global LSP keymaps via LspAttach (universal, recommended pattern)
local lsp_keys_grp = vim.api.nvim_create_augroup('UserLspKeys', { clear = true })
vim.api.nvim_create_autocmd('LspAttach', {
Expand All @@ -52,6 +63,8 @@ return {
nmap('K', vim.lsp.buf.hover, 'Hover Documentation')
nmap('<C-k>', vim.lsp.buf.signature_help, 'Signature Documentation')
nmap('gD', vim.lsp.buf.declaration, '[G]oto [D]eclaration')
local client = args.data and vim.lsp.get_client_by_id(args.data.client_id) or nil
enable_inlay_hints(client, bufnr)
end,
})

Expand Down Expand Up @@ -87,6 +100,8 @@ return {
vim.api.nvim_buf_create_user_command(bufnr, 'Format', function(_)
vim.lsp.buf.format()
end, { desc = 'Format current buffer with LSP' })

enable_inlay_hints(client, bufnr)
end

-- Enable the following language servers
Expand Down Expand Up @@ -168,4 +183,8 @@ return {
}
end,
},
{
'qvalentin/helm-ls.nvim',
ft = 'helm',
},
}
12 changes: 12 additions & 0 deletions lua/coldboot/plugins/oil.lua
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,13 @@ return {
default_file_explorer = true,
-- Send deleted files to the trash instead of permanently deleting them (:help oil-trash)
delete_to_trash = true,
-- Reserve space for git status indicators injected by oil-git-status.nvim
win_options = {
signcolumn = 'yes:2',
},
lsp_file_methods = {
enabled = true,
},
view_options = {
-- Show files and directories that start with "."
show_hidden = true,
Expand All @@ -35,4 +42,9 @@ return {
-- Optional dependencies
dependencies = { 'nvim-tree/nvim-web-devicons' },
},
{
'refractalize/oil-git-status.nvim',
dependencies = { 'stevearc/oil.nvim' },
config = true,
},
}
Loading