Public Access
change mini.files open location
This commit is contained in:
@@ -18,11 +18,18 @@ local function telescope_picker(picker)
|
||||
end
|
||||
end
|
||||
|
||||
local function open_mini_files_at_current_buffer()
|
||||
local current_path = vim.api.nvim_buf_get_name(0)
|
||||
if vim.bo.buftype ~= "" or current_path == "" then
|
||||
current_path = nil
|
||||
end
|
||||
|
||||
MiniFiles.open(current_path)
|
||||
end
|
||||
|
||||
map("n", "<leader><leader>r", ":source ~/.config/nvim/init.lua<CR>", { desc = "reload init.lua" })
|
||||
map("n", "<leader><leader>h", telescope_picker("keymaps"), { desc = "show keymaps" })
|
||||
map("n", "<leader>e", function()
|
||||
MiniFiles.open()
|
||||
end, { desc = "open mini.files" })
|
||||
map("n", "<leader>e", open_mini_files_at_current_buffer, { desc = "open mini.files" })
|
||||
map("n", "<leader>ff", telescope_picker("find_files"), { desc = "find files" })
|
||||
map("n", "<leader>fg", telescope_picker("live_grep"), { desc = "live grep" })
|
||||
map("n", "<leader>fb", telescope_picker("buffers"), { desc = "find buffers" })
|
||||
|
||||
Reference in New Issue
Block a user