{ plugins.telescope = { enable = true; extensions = { fzf-native = { enable = true; }; ui-select = { settings = { specific_opts = { codeactions = true; }; }; }; undo = { enable = true; }; }; # If you'd prefer Telescope not to enter a normal-like mode when hitting escape (and instead exiting), you can map to do so via: settings = { defaults = { mappings = { i = { "" = { __raw = '' function(...) return require("telescope.actions").close(...) end''; }; }; }; }; }; keymaps = { "" = { action = "find_files"; options.desc = "Find project files"; }; "/" = { action = "live_grep"; options.desc = "Grep (root dir)"; }; ":" = { action = "command_history"; options.desc = "Command History"; }; "b" = { action = "buffers"; options.desc = "+buffer"; }; "ff" = { action = "find_files"; options.desc = "Find project files"; }; "fr" = { action = "oldfiles"; options.desc = "Recent"; }; "fb" = { action = "buffers"; options.desc = "Buffers"; }; "" = { action = "git_files"; options.desc = "Search git files"; }; "gc" = { action = "git_commits"; options.desc = "Commits"; }; "gs" = { action = "git_status"; options.desc = "Status"; }; "sa" = { action = "autocommands"; options.desc = "Auto Commands"; }; "sb" = { action = "current_buffer_fuzzy_find"; options.desc = "Buffer"; }; "sc" = { action = "command_history"; options.desc = "Command History"; }; "sC" = { action = "commands"; options.desc = "Commands"; }; "sD" = { action = "diagnostics"; options.desc = "Workspace diagnostics"; }; "sh" = { action = "help_tags"; options.desc = "Help pages"; }; "sH" = { action = "highlights"; options.desc = "Search Highlight Groups"; }; "sk" = { action = "keymaps"; options.desc = "Keymaps"; }; "sM" = { action = "man_pages"; options.desc = "Man pages"; }; "sm" = { action = "marks"; options.desc = "Jump to Mark"; }; "so" = { action = "vim_options"; options.desc = "Options"; }; "sR" = { action = "resume"; options.desc = "Resume"; }; "uC" = { action = "colorscheme"; options.desc = "Colorscheme preview"; }; }; }; keymaps = [ { mode = "n"; key = "fp"; action = "Telescope projects"; options = { desc = "Projects"; }; } { mode = "n"; key = "sd"; action = "Telescope diagnostics bufnr=0"; options = { desc = "Document diagnostics"; }; } { mode = "n"; key = "st"; action = "TodoTelescope"; options = { silent = true; desc = "Todo (Telescope)"; }; } # { # mode = "n"; # key = ","; # action = "Telescope buffers sort_mru=true sort_lastused=true"; # options = { # desc = "Switch Buffer"; # }; # } ]; extraConfigLua = '' local telescope = require('telescope') telescope.setup{ pickers = { colorscheme = { enable_preview = true } } } ''; }