diff --git a/init.lua b/init.lua index e5259cf3..a5355a8c 100644 --- a/init.lua +++ b/init.lua @@ -728,17 +728,6 @@ require('lazy').setup({ -- -- You can use 'stop_after_first' to run the first available formatter from the list -- javascript = { "prettierd", "prettier", stop_after_first = true }, - - -- my customizations - json = { 'jq' }, - sarif = { 'jq' }, - python = { 'ruff_format', 'ruff_organize_imports' }, - html = { 'prettier' }, - javascript = { 'prettier' }, - typescript = { 'prettier' }, - typescriptreact = { 'prettier' }, - markdown = { 'markdownlint' }, - yaml = { 'prettier' }, }, }, }, diff --git a/lua/custom/plugins/conform.lua b/lua/custom/plugins/conform.lua new file mode 100644 index 00000000..0a554f77 --- /dev/null +++ b/lua/custom/plugins/conform.lua @@ -0,0 +1,16 @@ +return { + 'stevearc/conform.nvim', + opts = { + formatters_by_ft = { + json = { 'jq' }, + sarif = { 'jq' }, + python = { 'ruff_format', 'ruff_organize_imports' }, + html = { 'prettier' }, + javascript = { 'prettier' }, + typescript = { 'prettier' }, + typescriptreact = { 'prettier' }, + markdown = { 'markdownlint' }, + yaml = { 'prettier' }, + }, + }, +}