diff options
author | Gustaf Rydholm <gustaf.rydholm@gmail.com> | 2022-04-06 22:37:38 +0200 |
---|---|---|
committer | Gustaf Rydholm <gustaf.rydholm@gmail.com> | 2022-04-06 22:37:38 +0200 |
commit | ad2c268442300514ef18420f6b69f9053cb448cf (patch) | |
tree | 724d750d0532c884c261e18115bae421f7c37f17 /fnl | |
parent | 9ae371fc6c94765862719a2c57554ab98794cecd (diff) |
feat(null ls): add fnl config
Diffstat (limited to 'fnl')
-rw-r--r-- | fnl/config/lsp/null-ls.fnl | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/fnl/config/lsp/null-ls.fnl b/fnl/config/lsp/null-ls.fnl new file mode 100644 index 0000000..b2bc1e2 --- /dev/null +++ b/fnl/config/lsp/null-ls.fnl @@ -0,0 +1,29 @@ +;; Adds LSP diagnostics and formatting. +(module config.lsp.null-ls + {autoload {util util}}) + +(let [(ok? null-ls) util.load-plugin :null-ls] + (when ok? + (let [formatting null_ls.builtins.formatting diagnostics null_ls.builtins.diagnostics]) + (null-ls.setup + {:debug false + :sources [ + (diagnostics.flake8) + (diagnostics.golangci_lint) + (diagnostics.jsonlint) + (diagnostics.shellcheck) + (diagnostics.yamllint) + (formatting.black.with { extra_args [ "--fast" ] }) + (formatting.erlfmt) + (formatting.fourmolu) + (formatting.gofmt) + (formatting.goimports) + (formatting.nixfmt) + (formatting.prettier.with { + extra_args [ "--no-semi" "--single-quote" "--jsx-single-quote" ] + }) + (formatting.rustfmt) + (formatting.shfmt) + (formatting.sqlformat) + (formatting.stylua) + (formatting.terraform_fmt)]}))) |