Fixed autocompletion & snippets
This commit is contained in:
@ -19,7 +19,10 @@
|
|||||||
"lazy.nvim": { "branch": "main", "commit": "e916f41df26e33b01f1b3ebe28881090da3a7281" },
|
"lazy.nvim": { "branch": "main", "commit": "e916f41df26e33b01f1b3ebe28881090da3a7281" },
|
||||||
"lazygit.nvim": { "branch": "main", "commit": "32bffdebe273e571588f25c8a708ca7297928617" },
|
"lazygit.nvim": { "branch": "main", "commit": "32bffdebe273e571588f25c8a708ca7297928617" },
|
||||||
"lsp-colors.nvim": { "branch": "main", "commit": "d0b245232aeb197bbd097111d8b69621b0671edb" },
|
"lsp-colors.nvim": { "branch": "main", "commit": "d0b245232aeb197bbd097111d8b69621b0671edb" },
|
||||||
|
"lualine.nvim": { "branch": "master", "commit": "e99d733e0213ceb8f548ae6551b04ae32e590c80" },
|
||||||
"markdown-preview.nvim": { "branch": "master", "commit": "02cc3874738bc0f86e4b91f09b8a0ac88aef8e96" },
|
"markdown-preview.nvim": { "branch": "master", "commit": "02cc3874738bc0f86e4b91f09b8a0ac88aef8e96" },
|
||||||
|
"mason-lspconfig.nvim": { "branch": "main", "commit": "93e58e100f37ef4fb0f897deeed20599dae9d128" },
|
||||||
|
"mason.nvim": { "branch": "main", "commit": "fecabaff94c34bf8ed9c3b2a45d42a5906ea251c" },
|
||||||
"mini.fuzzy": { "branch": "stable", "commit": "e8faf897330eadb1b1b76da67eeff04be85cbd8b" },
|
"mini.fuzzy": { "branch": "stable", "commit": "e8faf897330eadb1b1b76da67eeff04be85cbd8b" },
|
||||||
"mini.move": { "branch": "main", "commit": "a0c5930e33e55467b0a9f3bca93d8f6fdbfac2e4" },
|
"mini.move": { "branch": "main", "commit": "a0c5930e33e55467b0a9f3bca93d8f6fdbfac2e4" },
|
||||||
"mini.pairs": { "branch": "stable", "commit": "4ebc1ff8d77fe75e8f219432302800ca29e17614" },
|
"mini.pairs": { "branch": "stable", "commit": "4ebc1ff8d77fe75e8f219432302800ca29e17614" },
|
||||||
|
|||||||
@ -1,9 +1,24 @@
|
|||||||
return {
|
return {
|
||||||
|
|
||||||
----------------------------------------------------------------
|
----------------------------------------------------------------
|
||||||
-- LSP and Autocomplete Plugins
|
-- LSP and Autocomplete Plugins
|
||||||
-- They should be pulled first!
|
-- They should be pulled first!
|
||||||
-----------------------------------------------------------------
|
-----------------------------------------------------------------
|
||||||
|
{'williamboman/mason.nvim',
|
||||||
|
config = function() require("mason").setup({
|
||||||
|
ui = {
|
||||||
|
icons = {
|
||||||
|
package_installed = "✓",
|
||||||
|
package_pending = "➜",
|
||||||
|
package_uninstalled = "✗"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
|
end,
|
||||||
|
},
|
||||||
|
{ 'williamboman/mason-lspconfig.nvim',
|
||||||
|
config = function() require("mason-lspconfig").setup{} end,
|
||||||
|
},
|
||||||
|
{ 'neovim/nvim-lspconfig' },
|
||||||
|
|
||||||
-- Manage all your Keymaps!
|
-- Manage all your Keymaps!
|
||||||
{
|
{
|
||||||
@ -12,16 +27,24 @@ return {
|
|||||||
before = "telescope.nvim"
|
before = "telescope.nvim"
|
||||||
},
|
},
|
||||||
|
|
||||||
-- Neovim Autocomplete with LSP
|
|
||||||
{
|
{
|
||||||
'L3MON4D3/LuaSnip', version = "1.2.1",
|
'L3MON4D3/LuaSnip', version = "1.2.1",
|
||||||
wants = { "friendly-snippets", "vim-snippets" },
|
dependencies = { "friendly-snippets" },
|
||||||
},
|
},
|
||||||
|
'saadparwaiz1/cmp_luasnip',
|
||||||
|
'hrsh7th/cmp-nvim-lsp-signature-help',
|
||||||
|
|
||||||
------------------------------------------------------------
|
------------------------------------------------------------
|
||||||
-- General Functionality
|
-- General Functionality
|
||||||
------------------------------------------------------------
|
------------------------------------------------------------
|
||||||
'kdheepak/lazygit.nvim',
|
'kdheepak/lazygit.nvim',
|
||||||
|
{
|
||||||
|
'nvim-lualine/lualine.nvim',
|
||||||
|
dependencies = { 'kyazdani42/nvim-web-devicons' },
|
||||||
|
config = function() require('lualine').setup{
|
||||||
|
options = { theme = 'codedark' }
|
||||||
|
} end,
|
||||||
|
},
|
||||||
-- Tmux Navigation
|
-- Tmux Navigation
|
||||||
{
|
{
|
||||||
"aserowy/tmux.nvim",
|
"aserowy/tmux.nvim",
|
||||||
|
|||||||
@ -1,22 +0,0 @@
|
|||||||
return {
|
|
||||||
-- Easy Way to install Language Servers
|
|
||||||
{ 'williamboman/mason.nvim',
|
|
||||||
'williamboman/mason-lspconfig.nvim',
|
|
||||||
'neovim/nvim-lspconfig',
|
|
||||||
},
|
|
||||||
|
|
||||||
config = function()
|
|
||||||
require("mason").setup()
|
|
||||||
local lsp_installer = require("mason-lspconfig").setup({
|
|
||||||
automatic_instalsation = true,
|
|
||||||
ui = {
|
|
||||||
icons = {
|
|
||||||
server_installed = "✓",
|
|
||||||
server_pending = "➜",
|
|
||||||
server_uninstalled = "✗"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
})
|
|
||||||
end
|
|
||||||
|
|
||||||
}
|
|
||||||
@ -22,7 +22,10 @@ return {
|
|||||||
if not luasnip_status_ok then
|
if not luasnip_status_ok then
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
--cmp.setup {
|
|
||||||
|
require("luasnip.loaders.from_vscode").lazy_load()
|
||||||
|
|
||||||
|
cmp.setup {
|
||||||
-- Load snippet support
|
-- Load snippet support
|
||||||
--snippet = {
|
--snippet = {
|
||||||
-- expand = function(args)
|
-- expand = function(args)
|
||||||
@ -33,7 +36,7 @@ return {
|
|||||||
completion = {
|
completion = {
|
||||||
--completeopt = 'menu,menuone,noselect'
|
--completeopt = 'menu,menuone,noselect'
|
||||||
keyword_length = 2
|
keyword_length = 2
|
||||||
}
|
},
|
||||||
|
|
||||||
-- Key mapping
|
-- Key mapping
|
||||||
mapping = {
|
mapping = {
|
||||||
@ -68,9 +71,13 @@ return {
|
|||||||
else
|
else
|
||||||
fallback()
|
fallback()
|
||||||
end
|
end
|
||||||
end
|
end,
|
||||||
}
|
},
|
||||||
|
snippet = {
|
||||||
|
expand = function(args)
|
||||||
|
require('luasnip').lsp_expand(args.body)
|
||||||
|
end,
|
||||||
|
},
|
||||||
-- Load sources, see: https://github.com/topics/nvim-cmp
|
-- Load sources, see: https://github.com/topics/nvim-cmp
|
||||||
sources = {
|
sources = {
|
||||||
{ name = 'nvim-lsp' },
|
{ name = 'nvim-lsp' },
|
||||||
@ -79,5 +86,6 @@ return {
|
|||||||
{ name = 'buffer' },
|
{ name = 'buffer' },
|
||||||
{ name = 'zsh' },
|
{ name = 'zsh' },
|
||||||
}
|
}
|
||||||
|
}
|
||||||
end
|
end
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user