diff --git a/lua/my_plugins.lua b/lua/my_plugins.lua index 97ff677..a17c2a1 100644 --- a/lua/my_plugins.lua +++ b/lua/my_plugins.lua @@ -106,6 +106,7 @@ return require('packer').startup(function() { 'f3fora/cmp-spell' }, { 'hrsh7th/cmp-emoji' }, { 'hrsh7th/cmp-cmdline' }, + { 'dmitmel/cmp-cmdline-history'}, { 'ray-x/cmp-treesitter' }, { 'hrsh7th/cmp-nvim-lsp-signature-help' }, { 'p00f/clangd_extensions.nvim' }, diff --git a/lua/setup/cmp.lua b/lua/setup/cmp.lua index 21e1a8c..5cf2b51 100644 --- a/lua/setup/cmp.lua +++ b/lua/setup/cmp.lua @@ -112,13 +112,12 @@ cmp.setup.cmdline('/', { -- Use cmdline & path source for ':' (if you enabled `native_menu`, this won't work anymore). cmp.setup.cmdline(':', { - sources = cmp.config.sources({ - { name = 'path' }, - }, { + sources = { { name = 'cmdline' }, - }, { + { name = 'cmdline_history' }, + { name = 'path' }, { name = 'buffer' }, - }), + }, }) require('cmp').setup.filetype({ 'dap-repl', 'dapui_watches', 'dapui_hover' }, {