mirror of
https://github.com/NotAShelf/nvf.git
synced 2025-04-01 10:41:52 +00:00
language/elixir: migrate to conform/nvim-lint
This commit is contained in:
parent
459e97dab7
commit
07384c3887
1 changed files with 9 additions and 10 deletions
|
@ -38,14 +38,9 @@
|
|||
formats = {
|
||||
mix = {
|
||||
package = pkgs.elixir;
|
||||
nullConfig = ''
|
||||
table.insert(
|
||||
ls_sources,
|
||||
null_ls.builtins.formatting.mix.with({
|
||||
command = "${cfg.format.package}/bin/mix",
|
||||
})
|
||||
)
|
||||
'';
|
||||
config = {
|
||||
command = "${cfg.format.package}/bin/mix";
|
||||
};
|
||||
};
|
||||
};
|
||||
in {
|
||||
|
@ -107,8 +102,12 @@ in {
|
|||
})
|
||||
|
||||
(mkIf cfg.format.enable {
|
||||
vim.lsp.null-ls.enable = true;
|
||||
vim.lsp.null-ls.sources.elixir-format = formats.${cfg.format.type}.nullConfig;
|
||||
vim.formatter.conform-nvim = {
|
||||
enable = true;
|
||||
setupOpts.formatters_by_ft.elixir = [cfg.format.type];
|
||||
setupOpts.formatters.${cfg.format.type} =
|
||||
formats.${cfg.format.type}.config;
|
||||
};
|
||||
})
|
||||
|
||||
(mkIf cfg.elixir-tools.enable {
|
||||
|
|
Loading…
Add table
Reference in a new issue