fixed issues with telescope after deleting old packer folders
This commit is contained in:
parent
11bdbf9942
commit
664f0b6e1a
2 changed files with 23 additions and 10 deletions
|
@ -8,10 +8,3 @@ vim.keymap.set('n', '<C-j>', '<C-w>j')
|
||||||
vim.keymap.set('n', '<C-k>', '<C-w>k')
|
vim.keymap.set('n', '<C-k>', '<C-w>k')
|
||||||
vim.keymap.set('n', '<C-h>', '<C-w>h')
|
vim.keymap.set('n', '<C-h>', '<C-w>h')
|
||||||
vim.keymap.set('n', '<C-l>', '<C-w>l')
|
vim.keymap.set('n', '<C-l>', '<C-w>l')
|
||||||
|
|
||||||
-- telescope keymaps
|
|
||||||
local builtin = require('telescope.builtin')
|
|
||||||
vim.keymap.set('n', '<leader>ff', builtin.find_files, {})
|
|
||||||
vim.keymap.set('n', '<leader>fg', builtin.live_grep, {})
|
|
||||||
vim.keymap.set('n', '<leader>fb', builtin.buffers, {})
|
|
||||||
vim.keymap.set('n', '<leader>fh', builtin.help_tags, {})
|
|
||||||
|
|
|
@ -1,5 +1,25 @@
|
||||||
return {
|
return {
|
||||||
'nvim-telescope/telescope.nvim', tag = '0.1.8',
|
'nvim-telescope/telescope.nvim',
|
||||||
|
cmd = 'Telescope',
|
||||||
dependencies = { 'nvim-lua/plenary.nvim' }
|
dependencies = {
|
||||||
|
'nvim-lua/plenary.nvim'
|
||||||
|
},
|
||||||
|
keys = function()
|
||||||
|
local lazy_telescope = function(builtin)
|
||||||
|
return function(...)
|
||||||
|
require('telescope.builtin')[builtin](...)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
return {
|
||||||
|
{ '<leader>fb', lazy_telescope('buffers'), desc = 'Find buffers' },
|
||||||
|
{ '<leader>fd', lazy_telescope('diagnostics'), desc = 'Find diagnostics' },
|
||||||
|
{ '<leader>ff', lazy_telescope('find_files'), desc = 'Find files' },
|
||||||
|
{ '<leader>fg', lazy_telescope('live_grep'), desc = 'Find files by content'},
|
||||||
|
{ '<leader>fh', lazy_telescope('help_tags'), desc = 'Find help tags' },
|
||||||
|
{ '<leader>fo', lazy_telescope('oldfiles'), desc = 'Find recently opened files' },
|
||||||
|
{ '<leader>fw', lazy_telescope('grep_string'), desc = 'Find word in buffer' },
|
||||||
|
{ '<leader>f/', lazy_telescope('current_buffer_fuzzy_find'), desc = 'Find fuzzy match in current buffer' },
|
||||||
|
}
|
||||||
|
end,
|
||||||
|
config = true,
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue