-
Notifications
You must be signed in to change notification settings - Fork 176
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
bug: Nested injection does not get formatted #607
Comments
You're customizing |
if a read the docs right |
I'm saying to try it here formatters = {
injected = {
options = {
ignore_errors = false,
lang_to_formatters = {
sql = { "sqlfluff" },
rust = { "rustfmt", "injected" }, -- this line
},
},
}
} That should only affect how you format rust that is embedded in other languages, not a standalone rust file that would have a language server attached |
oh now I see. this way it works. It is a little inconvenient to think about what possible combinations of injections my files could have, I expected it to look at |
The injected formatter does look at |
Neovim version (nvim -v)
NVIM v0.10.2
Operating system/version
NixOS unstable-d70bd19e0a38ad4790d3913bf08fcbfc9eeca507
Read debugging tips
Add the debug logs
log_level = vim.log.levels.DEBUG
and pasted the log contents below.Log file
Describe the bug
Nested SQL injection in Rust code snippet inside Markdown file does not get formatted
instead I get formatting for everything but SQL (notice blank line gone,
;
at the right place but SQL untouched)What is the severity of this bug?
minor (annoyance)
Steps To Reproduce
example Markdown file:
Expected Behavior
I would expect to get something like this:
Minimal example file
Minimal init.lua
Additional context
No response
The text was updated successfully, but these errors were encountered: