caem
75b13ac379
With the release of the Nvidia 555 beta drivers and their improvements to the Wayland experience I've finally decided to return to NixOS with Hyprland again after 2 years of running Gentoo and Opensuse Tumbleweed on X11. So this is me committing the work done so far from the last couple of days. Future commits will be more incremental.
55 lines
1.4 KiB
Lua
55 lines
1.4 KiB
Lua
return {
|
|
"hrsh7th/nvim-cmp",
|
|
dependencies = {
|
|
"L3MON4D3/LuaSnip",
|
|
"saadparwaiz1/cmp_luasnip",
|
|
"hrsh7th/cmp-buffer",
|
|
"hrsh7th/cmp-path",
|
|
"hrsh7th/cmp-nvim-lsp",
|
|
{
|
|
"tamago324/cmp-zsh",
|
|
config = function()
|
|
require"cmp_zsh".setup {
|
|
zshrc = true,
|
|
filetypes = { "bash", "zsh", "sh" },
|
|
}
|
|
end,
|
|
},
|
|
"ray-x/cmp-treesitter",
|
|
"hrsh7th/cmp-nvim-lua",
|
|
"andersevenrud/cmp-tmux",
|
|
},
|
|
config = function()
|
|
local cmp = require"cmp"
|
|
cmp.setup {
|
|
snippet = {
|
|
expand = function(args)
|
|
require"luasnip".lsp_expand(args.body)
|
|
end,
|
|
},
|
|
view = {
|
|
entries = "native",
|
|
},
|
|
mapping = cmp.mapping.preset.insert {
|
|
['<C-k>'] = cmp.mapping.select_prev_item(),
|
|
['<C-j>'] = cmp.mapping.select_next_item(),
|
|
['<A-j>'] = cmp.mapping.scroll_docs(4),
|
|
['<A-k>'] = cmp.mapping.scroll_docs(-4),
|
|
['<S-CR>'] = cmp.mapping.complete(),
|
|
['<C-Space>'] = cmp.mapping.confirm({ select = true }),
|
|
['<C-e>'] = cmp.mapping.abort(),
|
|
},
|
|
sources = {
|
|
{ name = "path" },
|
|
{ name = "luasnip" },
|
|
{ name = "zsh" },
|
|
{ name = "nvim_lsp" },
|
|
{ name = "buffer" },
|
|
{ name = "treesitter" },
|
|
{ name = "nvim-lua" },
|
|
{ name = "tmux" },
|
|
},
|
|
}
|
|
end
|
|
}
|
|
|