[Feature] better code action prompt and auto show codelens actions (#1698)

This commit is contained in:
Abouzar Parvan 2021-10-06 02:07:23 +03:30 committed by GitHub
parent 5fe7b7ad4d
commit 0ad60e90a9
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 43 additions and 1 deletions

View file

@ -159,6 +159,26 @@ function M.view_lunarvim_changelog()
}):find()
end
function M.code_actions()
local opts = {
winblend = 15,
layout_config = {
prompt_position = "top",
width = 80,
height = 12,
},
borderchars = {
prompt = { "", "", " ", "", "", "", "", "" },
results = { "", "", "", "", "", "", "", "" },
preview = { "", "", "", "", "", "", "", "" },
},
border = {},
previewer = false,
shorten_path = false,
}
require("telescope.builtin").lsp_code_actions(require("telescope.themes").get_dropdown(opts))
end
function M.setup()
local telescope = require "telescope"