local mapSilent = require("my.keymaps").mapSilent local M = {} local bindings = { -- Open files with control + P find_files = "", -- Search through files with control + F live_grep = "", -- See diagnostics with space + d lsp_document_diagnostics = "d", lsp_workspace_diagnostics = "wd", -- Open a list with all the pickers builtin = "t", -- List function, var names etc treesitter = "s", -- Git stuff git_commits = "gj", git_branches = "gk" } function M.setup() for action, keybind in pairs(bindings) do -- Maps the keybind to the action mapSilent('n', keybind, "lua require('telescope.builtin')." .. action .. "()") end require("telescope").setup {defaults = {mappings = {i = {[""] = "which_key"}}}} end return M