all: use treefmt for formatting everything

This commit is contained in:
Aaron Bieber 2024-06-28 09:27:48 -06:00
parent 6505bbb4ae
commit cdef7656ff
No known key found for this signature in database
2 changed files with 30 additions and 0 deletions

View File

@ -101,6 +101,8 @@ let
ssh-to-age
ssh-to-pgp
statix
treefmt2
perlPackages.PerlTidy
];
};

28
treefmt.toml Normal file
View File

@ -0,0 +1,28 @@
[formatter.statix]
command = "statix"
options = ["check"]
priority = 1
[formatter.deadnix]
command = "deadnix"
options = ["-f"]
includes = [ "*.nix" ]
priority = 2
[formatter.nix]
command = "nix"
options = ["fmt"]
includes = ["*.nix"]
priority = 3
[formatter.shfmt]
command = "shfmt"
options = ["-w"]
includes = ["*.sh", "bin/*"]
priority = 1
[formatter.perltidy]
command = "perltidy"
options = ["-b"]
includes = ["*.pl", "*.PL"]
priority = 1