From cf0bb60e0f5af4ffa7db2abdbf1735135799b05f Mon Sep 17 00:00:00 2001 From: Alejandro Angulo Date: Thu, 25 Jul 2024 20:35:03 -0700 Subject: [PATCH] Added telescope extensions --- config/default.nix | 2 +- config/plugins/telescope.nix | 33 +++++++++++++++++++++++++++++++++ 2 files changed, 34 insertions(+), 1 deletion(-) create mode 100644 config/plugins/telescope.nix diff --git a/config/default.nix b/config/default.nix index 779aafe..769d9e7 100644 --- a/config/default.nix +++ b/config/default.nix @@ -7,6 +7,7 @@ ./plugins/lsp.nix ./plugins/lualine.nix ./plugins/rhubarb.nix + ./plugins/telescope.nix ./plugins/vim-obsession.nix ]; @@ -61,7 +62,6 @@ ]; plugins = { - telescope.enable = true; treesitter.enable = true; tmux-navigator.enable = true; fugitive.enable = true; diff --git a/config/plugins/telescope.nix b/config/plugins/telescope.nix new file mode 100644 index 0000000..4ead35d --- /dev/null +++ b/config/plugins/telescope.nix @@ -0,0 +1,33 @@ +{ + plugins.telescope = { + enable = true; + extensions = { + file-browser = { + enable = true; + settings = { + hijack_netrw = true; + }; + }; + frecency.enable = true; + }; + }; + + keymaps = [ + { + action = "Telescope frecency"; + key = "f"; + } + { + action = "Telescope live_grep"; + key = "g"; + } + { + action = "Telescope file_browser path=%:p:h select_buffer=true"; + key = "b"; + } + { + action = "Telescope file_browser"; + key = "B"; + } + ]; +}