Better cmp, icons

This commit is contained in:
Trevor Vallender 2023-11-20 14:44:31 +00:00
parent 9925839cf4
commit 20fd30d8fe
4 changed files with 23 additions and 3 deletions

View File

@ -6,8 +6,7 @@
"git-messenger.vim": { "branch": "master", "commit": "8a61bdfa351d4df9a9118ee1d3f45edbed617072" }, "git-messenger.vim": { "branch": "master", "commit": "8a61bdfa351d4df9a9118ee1d3f45edbed617072" },
"gruvbox.nvim": { "branch": "main", "commit": "517b012757fbe7a4d6e507baf5cc75837e62734f" }, "gruvbox.nvim": { "branch": "main", "commit": "517b012757fbe7a4d6e507baf5cc75837e62734f" },
"lazy.nvim": { "branch": "main", "commit": "96584866b9c5e998cbae300594d0ccfd0c464627" }, "lazy.nvim": { "branch": "main", "commit": "96584866b9c5e998cbae300594d0ccfd0c464627" },
"mason-lspconfig.nvim": { "branch": "main", "commit": "ab640b38ca9fa50d25d2d249b6606b9456b628d5" }, "lspkind.nvim": { "branch": "master", "commit": "57610d5ab560c073c465d6faf0c19f200cb67e6e" },
"mason.nvim": { "branch": "main", "commit": "41e75af1f578e55ba050c863587cffde3556ffa6" },
"nvim-cmp": { "branch": "main", "commit": "0b751f6beef40fd47375eaf53d3057e0bfa317e4" }, "nvim-cmp": { "branch": "main", "commit": "0b751f6beef40fd47375eaf53d3057e0bfa317e4" },
"nvim-dap": { "branch": "master", "commit": "e154fdb6d70b3765d71f296e718b29d8b7026a63" }, "nvim-dap": { "branch": "master", "commit": "e154fdb6d70b3765d71f296e718b29d8b7026a63" },
"nvim-dap-ui": { "branch": "master", "commit": "34160a7ce6072ef332f350ae1d4a6a501daf0159" }, "nvim-dap-ui": { "branch": "master", "commit": "34160a7ce6072ef332f350ae1d4a6a501daf0159" },

View File

@ -18,3 +18,9 @@ vim.lsp.handlers["textDocument/signatureHelp"] = vim.lsp.with(
vim.diagnostic.config{ vim.diagnostic.config{
float={border=_border} float={border=_border}
} }
-- git-messenger
vim.g.git_messenger_floating_win_opts = {
border = _border
}
vim.g.git_messenger_include_diff = "current"

View File

@ -1,4 +1,5 @@
local cmp = require("cmp") local cmp = require("cmp")
local lspkind = require('lspkind')
cmp.setup({ cmp.setup({
snippet = { snippet = {
expand = function(args) expand = function(args)
@ -21,5 +22,17 @@ cmp.setup({
{ name = 'vsnip' }, { name = 'vsnip' },
{ name = 'path' }, { name = 'path' },
{ name = 'treesitter' }, { name = 'treesitter' },
}) }),
formatting = {
format = lspkind.cmp_format({
mode = "symbol_text",
menu = ({
buffer = "[Buffer]",
nvim_lsp = "[LSP]",
luasnip = "[LuaSnip]",
nvim_lua = "[Lua]",
latex_symbols = "[Latex]",
})
}),
}
}) })

View File

@ -39,6 +39,8 @@ require("lazy").setup({
"neovim/nvim-lspconfig", "neovim/nvim-lspconfig",
-- Icons for Treesitter/nvim-tree -- Icons for Treesitter/nvim-tree
"nvim-tree/nvim-web-devicons", "nvim-tree/nvim-web-devicons",
-- LSP icons
"onsails/lspkind.nvim",
-- LSP completion -- LSP completion
"sar/cmp-lsp.nvim", "sar/cmp-lsp.nvim",
-- Treesitter completion -- Treesitter completion