feat: Add formatter configuration for Rust in init.lua

This commit is contained in:
Juliano Barbosa 2024-10-10 15:07:52 -03:00 committed by Hypera User (aider)
parent 8f4791e72a
commit 78e39017e0
No known key found for this signature in database
GPG Key ID: EB8B440F57360B3D

View File

@ -831,16 +831,17 @@ require('lazy').setup({
}
end,
formatters_by_ft = {
bash = { 'shellcheck' },
hcl = { 'hclfmt' },
go = { 'goimports', 'gofumpt' },
lua = { 'stylua' },
-- Conform can also run multiple formatters sequentially
python = { 'isort', 'black' },
markdown = { 'inject' },
--
-- Conform can also run multiple formatters sequentially
-- You can use 'stop_after_first' to run the first available formatter from the list
bash = { 'shellcheck' },
go = { 'goimports', 'gofumpt' },
hcl = { 'hclfmt' },
javascript = { 'prettierd', 'prettier', stop_after_first = true },
lua = { 'stylua' },
markdown = { 'inject' },
python = { 'isort', 'black' },
rust = { 'rustfmt', lsp_format = 'fallback' },
terraform = { 'terraform_fmt' },
yaml = { 'yamlfmt' },
},