You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
use({
"princejoogie/dir-telescope.nvim",
-- telescope.nvim is a required dependencyrequires= {"nvim-telescope/telescope.nvim"},
config=function()
require("dir-telescope").setup({
-- these are the default options sethidden=true,
no_ignore=false,
show_preview=true,
follow_symlinks=false,
})
end,
})
Usage
dir-telescope can be used in two ways, either as a telescope extension or as user commands.
the commands will open a telescope picker with the list of directories in your current working directory.
you can select a directory by hitting Enter or select multiple directories to filter with Tab
it will then perform either a live_grep or find_files on your selected directories
(tip): <C-q> will save your queries in a quickfix list. this is the default binding for telescope.nvim
With Telescope extensions
require("telescope").load_extension("dir")
To use the extension simply run :Telescope dir live_grep or :Telescope dir find_files. These will respect the options you have set during configuration.
Setting keymaps for telescope extensions
vim.keymap.set("n", "<leader>fd", "<cmd>Telescope dir live_grep<CR>", { noremap=true, silent=true })
vim.keymap.set("n", "<leader>pd", "<cmd>Telescope dir find_files<CR>", { noremap=true, silent=true })