fix: nix fmt

This commit is contained in:
2026-06-20 18:52:12 +09:00
parent 48258665ae
commit 38d437dc3e
@@ -11,9 +11,22 @@ _: {
yaml.__raw = ''{ "prettierd", "prettier", stop_after_first = true }'';
markdown.__raw = ''{ "prettierd", "prettier", stop_after_first = true }'';
lua = [ "stylua" ];
nix = [ "alejandra" ];
nix.__raw = ''{ "nix_fmt", "alejandra", stop_after_first = true }'';
sh = [ "shfmt" ];
};
formatters.nix_fmt = {
command = "nix";
args = [
"fmt"
"$FILENAME"
];
stdin = false;
condition.__raw = ''
function()
return vim.fn.executable("nix") == 1 and vim.fn.filereadable(vim.fn.findfile("flake.nix", ".;")) == 1
end
'';
};
format_on_save.__raw = ''
function(_)
return { timeout_ms = 1000, lsp_format = "fallback" }