Replies: 1 comment 2 replies
-
|
I am currently using following config, is there a better way? vim.api.nvim_create_autocmd("BufWritePre", {
callback = function()
if vim.bo.ft == "java" then
vim.lsp.buf.code_action({
context = { only = { "source.organizeImports" } },
apply = true,
})
end
end,
}) |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Does anyone know how to config to do that? Thanks.
Beta Was this translation helpful? Give feedback.
All reactions