Skip to content

Commit

Permalink
refactor(nvim): remove luasnip in favor of native vim.snippet
Browse files Browse the repository at this point in the history
  • Loading branch information
kutsan committed Apr 20, 2024
1 parent b2513fe commit 6ff1600
Show file tree
Hide file tree
Showing 4 changed files with 1 addition and 53 deletions.
1 change: 0 additions & 1 deletion .config/nvim/lazy-lock.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
"cmp-cmdline": { "branch": "main", "commit": "d250c63aa13ead745e3a40f61fdd3470efde3923" },
"cmp-lsp": { "branch": "main", "commit": "5af77f54de1b16c34b23cba810150689a3a90312" },
"cmp-lsp-signature-help": { "branch": "main", "commit": "3d8912ebeb56e5ae08ef0906e3a54de1c66b92f1" },
"cmp-luasnip": { "branch": "master", "commit": "05a9ab28b53f71d1aece421ef32fee2cb857a843" },
"cmp-path": { "branch": "main", "commit": "91ff86cd9c29299a64f968ebb45846c485725f23" },
"cokeline": { "branch": "main", "commit": "8b877a972337623f3f28f85a71611b2a08911b3a" },
"colorizer": { "branch": "master", "commit": "36c610a9717cc9ec426a07c8e6bf3b3abcb139d6" },
Expand Down
6 changes: 1 addition & 5 deletions .config/nvim/lua/specs/cmp.lua
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,7 @@ Plugin.dependencies = {
{ 'hrsh7th/cmp-cmdline', name = 'cmp-cmdline' },
{ 'hrsh7th/cmp-nvim-lsp', name = 'cmp-lsp' },
{ 'hrsh7th/cmp-nvim-lsp-signature-help', name = 'cmp-lsp-signature-help' },
{ 'saadparwaiz1/cmp_luasnip', name = 'cmp-luasnip' },
{ 'hrsh7th/cmp-path', name = 'cmp-path' },
'luasnip',
'autopairs',
}

Expand Down Expand Up @@ -50,8 +48,7 @@ Plugin.opts = function()
return {
snippet = {
expand = function(args)
local luasnip = require('luasnip')
luasnip.lsp_expand(args.body)
vim.snippet.expand(args.body)
end,
},
completion = {
Expand Down Expand Up @@ -136,7 +133,6 @@ Plugin.opts = function()
sources = cmp.config.sources({
{ name = 'nvim_lsp' },
{ name = 'nvim_lsp_signature_help' },
{ name = 'luasnip' },
{ name = 'calc' },
}, {
{ name = 'buffer' },
Expand Down
45 changes: 0 additions & 45 deletions .config/nvim/lua/specs/luasnip.lua

This file was deleted.

2 changes: 0 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@
- [`cmp-cmdline`](https://github.com/hrsh7th/cmp-cmdline) - cmp source for cmdline
- [`cmp-lsp`](https://github.com/hrsh7th/cmp-nvim-lsp) - cmp source for LSP client
- [`cmp-lsp-signature-help`](https://github.com/hrsh7th/cmp-nvim-lsp-signature-help) - cmp source for LSP signatures
- [`cmp-luasnip`](https://github.com/saadparwaiz1/cmp_luasnip) - cmp source for luasnip snippets
- [`cmp-path`](https://github.com/hrsh7th/cmp-path) - cmp source for filesystem paths
- [`cokeline`](https://github.com/willothy/nvim-cokeline) - Bufferline
- [`colorizer`](https://github.com/norcalli/nvim-colorizer.lua) - High-performance color highlighter
Expand All @@ -42,7 +41,6 @@
- [`html-language-server`](https://github.com/vscode-langservers/vscode-html-languageserver-bin) - HTML Language Server
- [`json-language-server`](https://github.com/vscode-langservers/vscode-json-languageserver) - JSON Language Server
- [`lua-language-server`](https://github.com/sumneko/lua-language-server) - Lua Language Server
- [`luasnip`](https://github.com/L3MON4D3/LuaSnip) - High-performance snippet engine
- [`null-ls`](https://github.com/jose-elias-alvarez/null-ls.nvim) - Use language server to inject diagnostics, formatter etc.
- [`nvim-tree`](https://github.com/kyazdani42/nvim-tree.lua) - File explorer
- [`nvim-web-devicons`](https://github.com/kyazdani42/nvim-web-devicons) - Nerd Font icon API support
Expand Down

0 comments on commit 6ff1600

Please sign in to comment.