]> Arthur Taft Gitweb - nvim.git/blob - lua/plugins/format.lua
Initial commit
[nvim.git] / lua / plugins / format.lua
1 return {
2   {
3     "stevearc/conform.nvim",
4     opts = {
5       formatters_by_ft = {
6         python = { "ruff_fix", "ruff_format", "black" },
7         lua    = { "stylua" },
8         sh     = { "shfmt" },
9         bash   = { "shfmt" },
10         markdown = { "prettier", "mdformat" },
11         yaml   = { "prettier" },
12         json   = { "prettier" },
13         tex    = {}, -- optionally "latexindent"
14       },
15       notify_on_error = true,
16     },
17   },
18   {
19     "nvimtools/none-ls.nvim",
20     dependencies = { "nvim-lua/plenary.nvim" },
21     config = function()
22       local nls = require("null-ls")
23       nls.setup({
24         sources = {
25           nls.builtins.diagnostics.shellcheck,
26           nls.builtins.diagnostics.markdownlint,
27         },
28       })
29     end,
30   },
31 }