From 121082e8f286ee32897877057ff253f6d10c85ca Mon Sep 17 00:00:00 2001 From: Gustaf Rydholm Date: Mon, 17 Jan 2022 23:30:23 +0100 Subject: Add telescope window settings --- lua/config/telescope.lua | 24 +++++++++++++++++++++--- 1 file changed, 21 insertions(+), 3 deletions(-) (limited to 'lua/config/telescope.lua') diff --git a/lua/config/telescope.lua b/lua/config/telescope.lua index 1f1ea97..1447ec2 100644 --- a/lua/config/telescope.lua +++ b/lua/config/telescope.lua @@ -9,11 +9,30 @@ local actions = require("telescope.actions") telescope.setup({ defaults = { - prompt_prefix = " ", selection_caret = " ", path_display = { "smart" }, - + initial_mode = "insert", + selection_strategy = "reset", + sorting_strategy = "ascending", + layout_strategy = "horizontal", + layout_config = { + width = 0.75, + prompt_position = "top", + preview_cutoff = 120, + horizontal = { mirror = false }, + vertical = { mirror = false }, + }, + vimgrep_arguments = { + "rg", + "--color=never", + "--no-heading", + "--with-filename", + "--line-number", + "--column", + "--smart-case", + "--hidden", + }, mappings = { i = { [""] = actions.cycle_history_next, @@ -45,7 +64,6 @@ telescope.setup({ [""] = actions.complete_tag, [""] = actions.which_key, -- keys from pressing }, - n = { [""] = actions.close, [""] = actions.select_default, -- cgit v1.2.3-70-g09d2