config/packages/autofmt.nix
chloe caruso ff5e23efc2 feat: "autofmt" code formatter
different codebases use different formatters. autofmt looks for project
configuration to pick the correct formatter, allowing an editor to
simply point to the script and have all ambiguities resolved.

this commit overhauls the conform configuration to set up autofmt
correctly, as well installing it with 'pkgs.autofmt'

closes #6
2025-08-17 20:43:47 -07:00

14 lines
291 B
Nix

{ pkgs, ... }:
pkgs.writeShellApplication {
name = "autofmt";
runtimeInputs = with pkgs; [
# include only a couple of formatters by default
deno
nixfmt-rfc-style
dprint
rustfmt
zig
clang-tools
];
text = ''exec deno run -A ${../files/autofmt.js} "$@"'';
}