StyLua
StyLua copied to clipboard
feat: Stylua LSP server
closes #936
For now I did not get around to porting the VsCode extension to LSP, so the easiest way to try this out is to use nvim:
cargo install --git https://github.com/PolyMeilex/StyLua.git --branch lsp
vim.lsp.config["stylua-lsp"] = {
cmd = { "stylua", "--lsp" },
filetypes = { "lua" },
}
vim.lsp.enable("stylua-lsp")
Thanks for this, the implementation seems pretty reasonable to me!
I still need to give this a bit of a think though about whether I want to "bloat" stylua with this (tbh, i don't think it is much bloat). But it does seem like a nice feature to have, and would allow pretty easy set up with any IDE
Lovely, I have been using this daily for the last 5 months without any issues so I'm happy to see it land 🚀 ❤️