crates.nvim added

This commit is contained in:
krolyxon 2022-09-07 21:31:43 +05:30
parent 069e35a99c
commit 3c06b80f87
3 changed files with 31 additions and 1 deletions

View File

@ -85,6 +85,7 @@ local options = {
{ name = "buffer" },
{ name = "nvim_lua" },
{ name = "path" },
{ name = "crates" },
},
}

View File

@ -63,10 +63,32 @@ M.gitsigns = function()
changedelete = { hl = "GitSignsChange", text = "", numhl = "GitSignsChangeNr", linehl = "GitSignsChangeLn" },
},
}
gitsigns.setup(options)
end
M.crates = function ()
local present, crates = pcall(require, "crates")
if not present then
return
end
local options = {
popup = {
style = "minimal",
order = "rounded",
show_version_date = false,
show_dependency_version = true,
max_height = 30,
max_width = 20,
padding = 1,
autofocus = true,
},
}
crates.setup(options)
end
M.blankline = function()
local present, blankline = pcall(require, "indent_blankline")

View File

@ -70,6 +70,13 @@ local plugins = {
end,
},
["Saecki/crates.nvim"] = {
event = { "BufRead Cargo.toml" },
config = function ()
require("plugins.configs.others").crates()
end
},
-- load luasnips + cmp related in insert mode only
["rafamadriz/friendly-snippets"] = {