Open Tebro opened 2 months ago
This is a workaround.
By defining the following Lua function, you can clear the review highlights:
function CopilotChatReviewClear()
local ns = vim.api.nvim_create_namespace('copilot_review')
vim.diagnostic.reset(ns)
end
vim.api.nvim_create_user_command(
'CopilotChatReviewClear',
CopilotChatReviewClear,
{}
)
Then, run the command:
:CopilotChatReviewClear
Alternatively, if you don't need the highlights, you might also consider using the keymap below to silence the function callbacks:
require("CopilotChat").setup {
prompts = {
Review = {
callback = function(_, _)
-- do nothing
end,
},
},
end
When using :CopilotChatReview it will print its suggestions in chat, but also highlight them in the buffer. Would be nice to be able to clear this highlights.