return { "nvim-telescope/telescope.nvim", tag = '0.1.8', version = false, dependencies = { "nvim-lua/plenary.nvim", { "nvim-telescope/telescope-fzf-native.nvim", build = "make" }, "nvim-tree/nvim-web-devicons", "BurntSushi/ripgrep", "folke/todo-comments.nvim", }, config = function() local telescope = require("telescope") local actions = require("telescope.actions") telescope.setup({ defaults = { mappings = { i = { [""] = actions.move_selection_previous, -- move to prev result [""] = actions.move_selection_next, -- move to next result [""] = actions.send_selected_to_qflist + actions.open_qflist, }, }, file_ignore_patterns = { "node_modules", "dist", ".git", ".next" }, path_display = { "filename_first" }, sorting_strategy = "ascending", layout_strategy = "flex", layout_config = { horizontal = { prompt_position = "top", width = 0.9, height = 0.9, preview_width = 0.5, }, vertical = { width = 0.9, height = 0.9, }, }, }, pickers = { find_files = { hidden = true, no_ignore = true, }, }, extensions = { themes = { layout_strategy = "vertical", layout_config = { vertical = { height = 0.4, width = 0.4, prompt_position = "top", }, horizontal = { width = 0.8, height = 0.7, }, }, light_themes = { ignore = true, keywords = { "light", "day", "frappe", "latte", "dawn" }, }, enable_previewer = false, enable_live_preview = true, }, }, }) telescope.load_extension("fzf") -- set keymaps local keymap = vim.keymap -- for conciseness keymap.set("n", "ff", "Telescope find_files", { desc = "Fuzzy find files in cwd" }) keymap.set("n", "fr", "Telescope oldfiles", { desc = "Fuzzy find recent files" }) keymap.set("n", "fs", "Telescope live_grep", { desc = "Find string in cwd" }) keymap.set("n", "fc", "Telescope grep_string", { desc = "Find string under cursor in cwd" }) keymap.set("n", "ft", "TodoTelescope", { desc = "Find todos" }) end, }