chore(config): nvim: telescope file finding and preview

Signed-off-by: Ismo Vuorinen <ismo@ivuorinen.net>
This commit is contained in:
2025-08-06 16:23:55 +03:00
parent 0b11f6456a
commit d3ec2e7332
2 changed files with 6 additions and 3 deletions

View File

@@ -111,7 +111,7 @@ local lazy_plugins = function()
return require('telescope').extensions.lazy_plugins.lazy_plugins()
end
K.nl('f', ':Telescope fd --hidden=true<cr>', 'Find Files')
K.nl('f', ':Telescope find_files<cr>', 'Find Files')
K.nl(',', ':Telescope buffers<cr>', 'Find existing buffers')
K.nl('/', function() fuzzy_search() end, 'Fuzzily search in current buffer')

View File

@@ -37,15 +37,18 @@ return {
local vimgrep_arguments = { unpack(c.values.vimgrep_arguments) }
-- I want to search in hidden/dot files.
table.insert(vimgrep_arguments, '--hidden')
-- I don't want to search in the `.git` directory.
table.insert(vimgrep_arguments, '--hidden=true')
table.insert(vimgrep_arguments, '--glob')
-- I don't want to search in the `.git` directory.
table.insert(vimgrep_arguments, '!**/.git/*')
-- [[ Configure Telescope ]]
-- See `:help telescope` and `:help telescope.setup()`
t.setup {
defaults = {
preview = {
filesize_limit = 0.1, -- MB
},
-- `hidden = true` is not supported in text grep commands.
vimgrep_arguments = vimgrep_arguments,